Hi. We have a system which is composed of few applications. Each application at certain points need to generate an event to one of event logs. (Event logs is a table in a database having attributes that define event log number, event type and so on.) All event logs have certain common attributes, but every log has some specific attributes (so there'll be a sparse table). Every event log supports its own set of events. These events dictate which additional fields are to be written. Application knows event log number and event type it must generate at certain points of execution.
I'm looking for design patterns which will help us achieve this. We need to write a library usable by applications, so each developer will have an easy to use classes for the purpose of inserting event data. Speaking at the "code level", I want to reduce client code to call to a single method with a signature specific to event it needs to generate.
So far I came up with a Factory (most likely it'll be also a Singleton) which will have 10 methods (10 event logs). Each method generates an appropriate class (say, EventLog1Entry) which will provide method for writing data to db.
What to do further I do not know.
P.S. This is my first attempt to use some design pattern, so forgive me if I use professional terms too freely.