On Thu, 5 Feb 2004, Gary wrote:

> I need the factory method to be non-static.  Any
> reason why the code can't be changed as shown below? 
> I could first check for a static method, and then try
> to find an instance method if necessary.

In OJB you basically have two options for object creation:

1)

Use the factory pattern with a factory class having a static
no-arg creation method.

2)

Have a (private) no-arg constructor, and optionally, use 
initialization-method to specify an instance method (again no-arg) that is
called right after the object has been created, to initialize the
object. (This initialization method can also be used with the above
strategy).

If these won't suffice for you, then could you please give some more
details on what your particular scenario is (e.g. in pseudo code) ?

Tom


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to