I just started working for a government agency and I have come across an interesting problem: business rules depend on legislature and as such they have to respect the exact time periods that legislature has been active.
To give you an example, if a subject has applied for a subsidy on a certain date, than he has to be evaluated according to criteria that vas valid on that given date. That same subsidy, for someone that applied on some later date has different criteria. I was wondering if there is a known pattern to deal with these time-dependent rules in orderly fashion. At the moment, the code is sprinkled with expressions akin to:
if application.date >”July 17th, 2008”
What is the best way to manage this problem?