B
BillG
I am used to dealing with recordsets and I am using a coarse-grained object
and need to know if I am doing it correctly.
I have a class named Activity which represents an event being planned (golf
outing, dinner dance etc.). The Activity hold a list of Registrations which
represents some company or individual reserving a spot at the activity. The
Registration class holds a list of Attendees which represents the
individuals being registrered for the event. when the Activity is loaded
into memory to be displayed in a form, the activity object data access class
loads the registrations for that activity and the Registration DAL loads the
Attendees into memory. Once the activity is loaded into memory no more data
access occurs. As new registrations are more or new attendees are added,
they are added in memory to the lists of items. When the activity is saved,
the activity writes the registrations back to the table and the registration
writes the attendees back to its table. For an update I delete and insert
all the registrations and attendees for that activity rather than worrying
about updating them.
Is this the proper way to handle a coarse grained object?
Bill
and need to know if I am doing it correctly.
I have a class named Activity which represents an event being planned (golf
outing, dinner dance etc.). The Activity hold a list of Registrations which
represents some company or individual reserving a spot at the activity. The
Registration class holds a list of Attendees which represents the
individuals being registrered for the event. when the Activity is loaded
into memory to be displayed in a form, the activity object data access class
loads the registrations for that activity and the Registration DAL loads the
Attendees into memory. Once the activity is loaded into memory no more data
access occurs. As new registrations are more or new attendees are added,
they are added in memory to the lists of items. When the activity is saved,
the activity writes the registrations back to the table and the registration
writes the attendees back to its table. For an update I delete and insert
all the registrations and attendees for that activity rather than worrying
about updating them.
Is this the proper way to handle a coarse grained object?
Bill