11 #include "GDCore/Events/InstructionsList.h"
12 #include "GDCore/Events/EventVisitor.h"
13 #include "GDCore/Project/ProjectScopedContainers.h"
14 #include "GDCore/String.h"
21 class ObjectsContainer;
23 class ParameterMetadata;
53 bool skipDisabledEvents_ =
false;
70 virtual bool DoVisitEvent(
gd::BaseEvent& event) {
return false; };
80 virtual bool DoVisitLinkEvent(
gd::LinkEvent& event) {
return false; };
86 bool areConditions){};
127 AbstractArbitraryEventsWorker::VisitEventList(events);
146 : currentProjectScopedContainers(
nullptr){};
155 currentProjectScopedContainers = &projectScopedContainers;
156 AbstractArbitraryEventsWorker::VisitEventList(events);
163 return *currentProjectScopedContainers;
168 return currentProjectScopedContainers->GetObjectsContainersList();
198 void StopAnyEventIteration()
override;
199 virtual void VisitEvent(
const gd::BaseEvent& event)
override;
204 bool skipDisabledEvents_ =
false;
205 void VisitLinkEvent(
const gd::LinkEvent& linkEvent)
override;
208 void VisitInstruction(
const gd::Instruction& instruction,
bool isCondition);
226 virtual void DoVisitLinkEvent(
const gd::LinkEvent& linkEvent) {};
232 bool areConditions){};
238 bool isCondition) {};
243 virtual void DoVisitEventExpression(
const gd::Expression& expression,
247 bool shouldStopIteration;
268 AbstractReadOnlyArbitraryEventsWorker::VisitEventList(events);
287 : currentProjectScopedContainers(
nullptr){};
296 currentProjectScopedContainers = &projectScopedContainers;
298 AbstractReadOnlyArbitraryEventsWorker::VisitEventList(events);
305 return *currentProjectScopedContainers;
AbstractArbitraryEventsWorker is a base abstract class used to browse events (and instructions) and d...
Definition: ArbitraryEventsWorker.h:37
void SetSkipDisabledEvents(bool skip)
When enabled, disabled events and their entire subtree are skipped during traversal.
Definition: ArbitraryEventsWorker.h:46
ReadOnlyArbitraryEventsWorker is an abstract class used to browse events (and instructions)....
Definition: ArbitraryEventsWorker.h:186
void SetSkipDisabledEvents(bool skip)
When enabled, disabled events and their entire subtree are skipped during traversal.
Definition: ArbitraryEventsWorker.h:195
ArbitraryEventsWorker is an abstract class used to browse events (and instructions) and do some work ...
Definition: ArbitraryEventsWorker.h:118
void Launch(gd::EventsList &events)
Launch the worker on the specified events list.
Definition: ArbitraryEventsWorker.h:126
An events worker that will know about the context (the objects container). Useful for workers working...
Definition: ArbitraryEventsWorker.h:143
void Launch(gd::EventsList &events, const gd::ProjectScopedContainers &projectScopedContainers)
Launch the worker on the specified events list, giving the objects container on which the events are ...
Definition: ArbitraryEventsWorker.h:153
Base class defining an event.
Definition: Event.h:43
Visitor of any kind of event.
Definition: EventVisitor.h:26
A list of events.
Definition: EventsList.h:32
Class representing an expression used as a parameter of a gd::Instruction. This class is nothing more...
Definition: Expression.h:30
An instruction is a member of an event: It can be a condition or an action.
Definition: Instruction.h:30
Definition: InstructionsList.h:25
A link pointing to external events (or events of another layout) that should be included and run inst...
Definition: LinkEvent.h:17
A list of objects containers, useful for accessing objects in a scoped way, along with methods to acc...
Definition: ObjectsContainersList.h:29
Holds references to variables, objects, properties and other containers.
Definition: ProjectScopedContainers.h:36
ReadOnlyArbitraryEventsWorker is an abstract class used to browse events (and instructions)....
Definition: ArbitraryEventsWorker.h:259
void Launch(const gd::EventsList &events)
Launch the worker on the specified events list.
Definition: ArbitraryEventsWorker.h:267
An events worker that will know about the context (the objects container). Useful for workers working...
Definition: ArbitraryEventsWorker.h:284
virtual void DoOnLaunch(const gd::EventsList &events)
Called at the start of each Launch, before event traversal begins. Override this to perform setup whe...
Definition: ArbitraryEventsWorker.h:312
void Launch(const gd::EventsList &events, const gd::ProjectScopedContainers &projectScopedContainers)
Launch the worker on the specified events list, giving the objects container on which the events are ...
Definition: ArbitraryEventsWorker.h:294
Visitor of any kind of event.
Definition: EventVisitor.h:54
Definition: CommonTools.h:24