Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Event-based customization of Calendar behaviour #84

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

igneus
Copy link
Owner

@igneus igneus commented Mar 9, 2021

This is an alternative way to fix #80.

I have been considering something like this for a long time - to allow customization of Calendar behaviour through events (heavily used in the Symfony PHP framework and elsewhere).

Neat advantage of this solution compared to #81 is that it makes it easily possible to grant first Vespers to a celebration which wouldn't receive them per the standard logic of precedence. Most (if not all) other thinkable changes to the calendar logic are possible, some of them in multiple different ways.
Disadvantage is that it's now equally easy to turn a calendar in a complete mess which is hard to read and reason about. (As exemplified by implementation of the Ubi vero S. Ioannes Baptista patronus sit nationis vel dioecesis vel civitatis aut
communitatis religiosae...
code example.)

before I forgot they have a separate rank higher than Rank::PRIMARY
strongly inspired by previous experience with the Symfony EventDispatcher component
+ make Calendar instance available as event attribute
+ prefix event IDs with `calendar__`
... if they come from Rome and affect the whole church.

Other ad hoc changes can be implemented using individual custom
event listeners.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

June 23-25, 2022 (Sacred Heart & Nativity of St. John the Baptist)
1 participant