Thanks, James. I think, I'm going to use the second approach, but just in case will check, if Event object can work in this situation.
>Hi Nadya,
>
>I usually do it like your approach 2. Seems to be what I see most often.
>
>Your approach #1 would be something similar to the Mediator pattern described in the Design Patterns book by the GoF.
>
>Aloha,
>
>James
>
>>Hi everybody,
>>
>>For batch process which is going to be run at night I'm instantiating a biz obj in the program. I found, that I need to use some logic from another biz object. I may want to use more biz objects.
>>
>>So my question is how to approach this the best way:
>>
>>1. Put all biz objects into container and then I want to use some methods or properties from other object in the first object use:
>>
>>
>>this.parent.CalendarObject.somemethod()
>>
>>
>>2. Create an object reference in my main object. In its PostInitHook do something like
>>
>>this.NewObject('CalObj',"CalendarObject")
>>
>>
>>What is the preferable method?
>>
>>Thanks a lot in advance.
If it's not broken, fix it until it is.
My Blog