50 #ifndef _COMPOSITEEXECUTIONOBJECT_H_
51 #define _COMPOSITEEXECUTIONOBJECT_H_
57 #include "ncl/components/Node.h"
58 #include "ncl/components/ContextNode.h"
59 using namespace ::br::pucrio::telemidia::ncl::components;
61 #include "ncl/connectors/EventUtil.h"
62 using namespace ::br::pucrio::telemidia::ncl::connectors;
64 #include "ncl/link/Link.h"
65 using namespace ::br::pucrio::telemidia::ncl::link;
67 #include "IEventListener.h"
68 #include "FormatterEvent.h"
69 #include "PresentationEvent.h"
70 using namespace ::br::pucrio::telemidia::ginga::ncl::model::event;
72 #include "FormatterCausalLink.h"
73 #include "FormatterLink.h"
74 #include "LinkListener.h"
75 using namespace ::br::pucrio::telemidia::ginga::ncl::model::link;
77 #include "NodeNesting.h"
78 #include "CascadingDescriptor.h"
79 #include "ExecutionObject.h"
92 namespace components {
98 static const short mSleepTime = 800;
99 set<FormatterLink*> links;
100 set<Link*> uncompiledLinks;
102 set<FormatterEvent*> runningEvents;
103 set<FormatterEvent*> pausedEvents;
104 short lastTransition;
106 map<FormatterLink*, int> pendingLinks;
109 map<string, ExecutionObject*> execObjList;
111 pthread_mutex_t compositeMutex;
112 pthread_mutex_t parentMutex;
113 pthread_mutex_t stlMutex;
120 ILinkActionListener* seListener);
125 CascadingDescriptor *descriptor,
127 ILinkActionListener* seListener);
132 void initializeCompositeExecutionObject(
135 CascadingDescriptor *descriptor);
139 void suspendLinkEvaluation(
bool suspend);
141 bool containsExecutionObject(
string execObjId);
143 map<string, ExecutionObject*>* getExecutionObjects();
144 map<string, ExecutionObject*>* recursivellyGetExecutionObjects();
145 int getNumExecutionObjects();
147 set<Link*>* getUncompiledLinks();
148 bool containsUncompiledLink(Link* dataLink);
149 void removeLinkUncompiled(Link* ncmLink);
150 void setLinkCompiled(FormatterLink *formatterLink);
151 void addNcmLink(Link *ncmLink);
152 void removeNcmLink(Link *ncmLink);
153 void setAllLinksAsUncompiled(
bool isRecursive);
154 void setParentsAsListeners();
155 void unsetParentsAsListeners();
156 void eventStateChanged(
157 void* event,
short transition,
short previousState);
159 short getPriorityType();
161 void linkEvaluationStarted(FormatterCausalLink *link);
162 void linkEvaluationFinished(FormatterCausalLink *link,
bool start);
164 bool setPropertyValue(AttributionEvent* event,
string value);
167 void checkLinkConditions();
169 void listRunningObjects();
170 void listPendingLinks();
172 void lockComposite();
173 void unlockComposite();
186 #endif //_COMPOSITEEXECUTIONOBJECT_H_
Definition: CompositeExecutionObject.h:93
Definition: ExecutionObject.h:124