00001 #ifndef SIMOBJECTARRAYFACTORY_H_ 00002 #define SIMOBJECTARRAYFACTORY_H_ 00003 00004 #include <vector> 00005 00006 using std::vector; 00007 00008 #include "SimObjectFactory.h" 00009 #include "SimObject.h" 00010 00011 class RandomDistribution; 00012 class RandomEngine; 00013 00014 00015 class SimObjectArrayFactory : public SimObjectFactory 00016 { 00017 public: 00018 00019 SimObjectArrayFactory( vector< SimObjectFactory* > const & objectList); 00020 00021 SimObjectArrayFactory( size_t size = 0 ); 00022 00023 virtual ~SimObjectArrayFactory(); 00024 00025 virtual void add( SimObjectFactory const * const factory); 00026 00027 virtual void reset(); 00028 00030 virtual SimObject* create( void ); 00031 00033 virtual SimObject* create( RandomEngine *eng ); 00034 00036 virtual object_type_t getObjectTypeID() const; 00037 00038 private: 00039 00040 vector< SimObject* > simObjectList; 00041 00042 unsigned int cursor; 00043 00044 }; 00045 00046 #endif /*SimObjectArrayFACTORY_H_*/