VR-Forces Development_Version Class Documentation
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
aggregator.h
Go to the documentation of this file.
1 /*******************************************************************************
2 ** Copyright (c) 2008 MAK Technologies, Inc.
3 ** All rights reserved.
4 *******************************************************************************/
5 
8 
11 
12 #pragma once
13 
15 class DtVrfObject;
16 class DtVrfObjectManager;
19 class DtEntityIdentifier;
22 class DtSimMessage;
24 
25 #include <map>
26 #include <vlpi/entityIdentifier.h>
27 
33 {
34 public:
35 
37  DtAggregator(DtVrfObject& aggregate,
38  DtSubordinateObjectsList& subordinatesObjectList,
39  DtVrfObjectManager& vrfObjectManager,
40  DtVrfMessageInterface& messageInterface);
41 
43  virtual ~DtAggregator();
44 
45  virtual void init();
46 
48  virtual void startAggregation();
49 
51  virtual bool aggregationIsComplete() const;
52 
53 protected:
54 
55  virtual void startAggregation(DtVrfObject& parentObj,
56  DtSubordinateObjectsList& subordinateObjectsList);
57 
58  virtual void setObjectResources(DtVrfObject& Obj, DtSubordinateIndividualEntry* subIndEntry);
59 
60  virtual void sendSubordinateListRequestMsg(const DtEntityIdentifier& objIdent);
61 
62  virtual void removeAndDeleteSubordinates();
63 
64  static void subordinateListRequestMessageCallback(DtSimMessage* msg, void* usr);
65 
66  virtual void processSubordinateListRequestMessageCallback(
68  const DtSimulationAddress & sender);
69 
70  static void subordinateListMessageCallback(DtSimMessage* msg, void* usr);
71  virtual void processSubordinateListMessageCallback(DtIfSubordinateList* content);
72 
74  DtAggregator(const DtAggregator& orig);
75 
77  DtAggregator& operator=(
78  const DtAggregator& orig);
79 
80 protected:
81 
83 
85 
87 
88  std::map<unsigned long, DtEntityIdentifier> myRequestIDs;
89 
90  std::map<DtEntityIdentifier, DtSubordinateAggregateEntry*> myPendingSubordinateEntryResponses;
91 
92  static unsigned long nextRequestId;
93 
94  std::map<DtVrfObject*,DtSubordinateAggregateEntry*> myDisaggregatedSubordinates;
95 
97 };
98 

Document ID: Generated on Mon Jul 4 01:00:18 EDT 2016 from SVN revision 166489
Copyright © 2005-2015 VT MÄK. All Rights Reserved (www.mak.com)