Hi everybody,
I'm designing a generic container class, which I'd like to use on each page of the pageframe (or instead of pageframe).
I'd like to have a reference of all container's biz obj. What would be the right way of doing it?
1) Have an array property to keep object references of all biz objects. Let each container's instance add a code in its Init to add these objects to this array property. [Or it could be a separate method of the container called RegisterBizObjs, which is called from container's Init)]
In the container destroy do store .null. to this.aBizObjs to manually go garbage collection.
2) Use a collection class. But it then would be a first object in the container. How would I implement it?
I'm leaning towards the first idea. What do you think? Does it sound like a right approach?
Thanks.
If it's not broken, fix it until it is.
My Blog