Main Page   Namespace List   Class Hierarchy   Compound List   Compound Members  

ZThread::Factory Class Template Reference

#include <Factory.h>

List of all members.

Static Public Methods

T* create ()
F* setInstance (F *)
F* getInstance ()


Detailed Description

template<class T, class F = FactoryImpl<T>, class LOCK = Mutex> class ZThread::Factory

Author:
Eric Crahen
Version:
1.2.2
Date:
01-12-2001

Factory implementation.


Member Function Documentation

T * create ( ) [static]
 

Create a new instance using the currently set FactoryImpl

Returns:
T* - new product

F * getInstance ( ) [static]
 

Get the current instance of the Factory object. If no instance has been explicitly set with the setInstance() method, a new F created.

Returns:
F* - old instance

F * setInstance ( F * impl ) [static]
 

Set the instance of the desired Factory object

Parameters:
F   * - new instance
Returns:
F* - old instance

Postcondition:
the new instance will be owned by this Factory object. It will be deleted when this Factorys SingletonDestroyer goes out of scope (when the program terminates). The user must assume the responsibility of destroying the old instance that was previously managed by the Factory.
Parameters:
impl  


The documentation for this class was generated from the following file:
Generated at Fri Aug 31 09:08:00 2001 for ZThread by doxygen1.2.8 written by Dimitri van Heesch, © 1997-2001