So, I have this grand romantic scheme for an organiser. Theoretically, it will be web-service based (That is, the first interface I will program for it will be XML-RPC because the data lends itself to being presented in XML, and I know how to do XML-RPC already), which means that any number/type of clients can access it, So far, so hoopy, so propaganda. Now I have a problem.
First, a word about the construction of the system. N turns everything into an object, and objects become linked together. For example, a given event may contain a date to start, a date/time to end, Whether it can only be done on it’s own (i.e., can it clash with something), but linked to it may be a location, a URL, a newsgroup message and a person. Linked to the person may be a different location, and e-mail address, an event (birthday) and another person. All of that might be linked to the group “Bloggers”. (On top of this is the cross-server links, so we can say that Event404 on reef.water.gkhs.net is Event609 on angel.kryogenix.org and event42 on services.tolhonath.org, but that’s beside the point for the time being).
The problem comes with repeating dates. Some events in any person’s life will come around monthly, weekly, daily, or whatever. Some, however, might come on the first weekday of the month, or the second Sunday after Christmas, or something, and I have to be able to deal with that. The inelegant way would be to recalculate the repeating times from the first date until the requested range every time someone requests a list of appointments, which is ugly. The alternative is to calculate them all for a given period (say, for one year from the date of commencement, user configurable) and lasso them together with the generic grouping system, which makes editing the details (name, for example) complicated, and means that people will have to remember to link to the group of events rather than the event itself if that is to become a link for /every/ iteration of the event. Excess use of word Event in previous sentence, 200 point fine. On the plus side, that means it is /possible/ to link something in for just one event (For example, say the event is a trip to the Movies scheduled for every other Wednesday. Peter, Posie and Paul are the usual suspects for it, so they are linked to the group of events, but Ruthi will be in town this Wednesday, and so therefore is linked to this event but not the one in a fortnight’s time). On the minus side, it means many events that are technically the same thing. Or technically different things, depending on how you look at it.
Or, there is some other way of doing all this that hasn’t occurred to me yet, and it’s all giving me a headache.
Today, I succeeded in installing Scoop on reef, and failed to program a single line of Nomical *or* Epistula because of trying to work out what to do about the above.