[2408] | 1 | #ifndef __XIOS_CPoolNode__ |
---|
| 2 | #define __XIOS_CPoolNode__ |
---|
| 3 | |
---|
| 4 | #include "xios_spl.hpp" |
---|
| 5 | #include "attribute_enum.hpp" |
---|
| 6 | #include "attribute_enum_impl.hpp" |
---|
| 7 | #include "attribute_array.hpp" |
---|
| 8 | #include "declare_attribute.hpp" |
---|
| 9 | #include "object_template.hpp" |
---|
| 10 | #include "group_factory.hpp" |
---|
| 11 | #include "declare_group.hpp" |
---|
[2458] | 12 | #include "service_node.hpp" |
---|
[2408] | 13 | |
---|
| 14 | |
---|
| 15 | namespace xios |
---|
| 16 | { |
---|
| 17 | /// ////////////////////// Déclarations ////////////////////// /// |
---|
| 18 | |
---|
| 19 | class CPoolNodeGroup; |
---|
| 20 | class CPoolNodeAttributes; |
---|
| 21 | class CPoolNode; |
---|
| 22 | ///-------------------------------------------------------------- |
---|
| 23 | |
---|
| 24 | // Declare/Define CVarAttribute |
---|
| 25 | BEGIN_DECLARE_ATTRIBUTE_MAP(CPoolNode) |
---|
| 26 | #include "pool_attribute.conf" |
---|
| 27 | END_DECLARE_ATTRIBUTE_MAP(CPoolNode) |
---|
| 28 | |
---|
| 29 | ///-------------------------------------------------------------- |
---|
| 30 | |
---|
| 31 | class CPoolNode: public CObjectTemplate<CPoolNode> |
---|
| 32 | , public CPoolNodeAttributes |
---|
| 33 | { |
---|
| 34 | friend class CCPoolNodeGroup; |
---|
| 35 | |
---|
| 36 | /// typedef /// |
---|
| 37 | typedef CObjectTemplate<CPoolNode> SuperClass; |
---|
| 38 | typedef CPoolNodeAttributes SuperClassAttribute; |
---|
| 39 | |
---|
| 40 | public : |
---|
| 41 | |
---|
| 42 | typedef CPoolNodeAttributes RelAttributes; |
---|
| 43 | typedef CPoolNodeGroup RelGroup; |
---|
| 44 | |
---|
| 45 | /// Constructeurs /// |
---|
| 46 | CPoolNode(void) ; |
---|
| 47 | explicit CPoolNode(const StdString & id); |
---|
| 48 | CPoolNode(const CPoolNode & var); // Not implemented yet. |
---|
| 49 | CPoolNode(const CPoolNode * const var); // Not implemented yet. |
---|
| 50 | |
---|
| 51 | /// Destructeur /// |
---|
| 52 | virtual ~CPoolNode(void); |
---|
| 53 | |
---|
| 54 | public : |
---|
| 55 | /// Accesseurs statiques /// |
---|
| 56 | static StdString GetName(void) { return StdString("pool"); } |
---|
| 57 | static StdString GetDefName(void) { return StdString("pool"); } |
---|
| 58 | static ENodeType GetType(void) { return ePoolNode; } |
---|
| 59 | public: |
---|
| 60 | virtual void parse(xml::CXMLNode & node); |
---|
[2458] | 61 | void allocateRessources(void) ; |
---|
[2408] | 62 | |
---|
[2458] | 63 | private: |
---|
| 64 | std::vector<CServiceNode*> getAllServiceNodes(void) const {return this->vServiceNodeGroup->getAllChildren();} |
---|
| 65 | CServiceNodeGroup* getVirtualServiceNodeGroup(void) const {return this->vServiceNodeGroup; } |
---|
| 66 | void setVirtualServiceNodeGroup(CServiceNodeGroup* newVServiceNodeGroup) { this->vServiceNodeGroup = newVServiceNodeGroup; } |
---|
| 67 | CServiceNodeGroup* vServiceNodeGroup; |
---|
| 68 | |
---|
[2408] | 69 | }; // class CPoolNode |
---|
| 70 | ///-------------------------------------------------------------- |
---|
| 71 | |
---|
| 72 | // Declare/Define CPoolNodeGroup and CPoolNodeDefinition |
---|
| 73 | DECLARE_GROUP(CPoolNode); |
---|
| 74 | } // namespace xios |
---|
| 75 | |
---|
| 76 | #endif // __XIOS_CPoolNode__ |
---|
| 77 | |
---|