N
Noozer
I have two Classes in use in an ASP application...
The first Class is named "ORDER". It represents one job order. It has a
Delete method, among others, which deletes it from my database.
The second Class is named "ORDERS". It represents a collection of ORDER
objects. Basically an array of ORDER objects. It has a Remove method that
JUST removes the ORDER object from the collection - no data is erased.
If I execute ORDERS.Item(3).Delete, I'd expect that the ORDER with an index
of 3 would be deleted from my databse - BUT the ORDER object would still be
in my ORDERS collection class.
How can I have the ORDERS Class execute code to remove the ORDER, when I
execute the ORDER.Delete method?
I could write a Delete method in my collection class, but that's not very OO
friendly.
The first Class is named "ORDER". It represents one job order. It has a
Delete method, among others, which deletes it from my database.
The second Class is named "ORDERS". It represents a collection of ORDER
objects. Basically an array of ORDER objects. It has a Remove method that
JUST removes the ORDER object from the collection - no data is erased.
If I execute ORDERS.Item(3).Delete, I'd expect that the ORDER with an index
of 3 would be deleted from my databse - BUT the ORDER object would still be
in my ORDERS collection class.
How can I have the ORDERS Class execute code to remove the ORDER, when I
execute the ORDER.Delete method?
I could write a Delete method in my collection class, but that's not very OO
friendly.