CSCI 3081 - Drone Delivery System
composite_factory.h
Go to the documentation of this file.
1 
4 #ifndef COMPOSITE_FACTORY_H
5 #define COMPOSITE_FACTORY_H
6 
7 /*******************************************************************************
8  * Includes
9  ******************************************************************************/
10 #include <EntityProject/facade/delivery_system.h>
11 #include <vector>
12 #include <string>
13 
14 namespace csci3081 {
15 
16 /*******************************************************************************
17  * Class Definitions
18  ******************************************************************************/
25  public:
30 
35 
42 
68  IEntity* CreateEntity(const picojson::object& val);
69 
70  private:
71  std::vector<IEntityFactory*> factories;
72 };
73 
74 } // namespace csci3081
75 
76 
77 #endif // COMPOSITE_FACTORY_H
IEntity * CreateEntity(const picojson::object &val)
This is an inheritance function from IEntityFactory to create an approxiate Entity object based on th...
Definition: composite_factory.cc:20
CompositeFactory()
Constructor: this can do any setup your system necessitates.
Definition: composite_factory.cc:7
void AddFactory(IEntityFactory *)
This adds an IEntityFactory factory into the vector factories of composite class. ...
Definition: composite_factory.cc:16
Definition: asubject.cc:3
Definition: entity_factory.h:12
This is a derived class from IEntityFactory to manage all other factories (e.g. DroneFactory, PackageFactory, CustomerFactory...)
Definition: composite_factory.h:24
~CompositeFactory()
Destructor: this tear down/reset the memory space related to pointers.
Definition: composite_factory.cc:9
A movable object in a scene. Entities have position, direction and size.
Definition: entity.h:15