BPMN-OS
BPMN for optimization and simulation
Loading...
Searching...
No Matches
InstantEntry.cpp
Go to the documentation of this file.
1
#include "
InstantEntry.h
"
2
#include "
execution/engine/src/events/EntryEvent.h
"
3
#include <cassert>
4
5
using namespace
BPMNOS::Execution
;
6
7
InstantEntry::InstantEntry
()
8
{
9
}
10
11
std::shared_ptr<Event>
InstantEntry::dispatchEvent
(
const
SystemState
* systemState ) {
12
for
(
auto
& [token_ptr, request_ptr] : systemState->
pendingEntryDecisions
) {
13
if
(
auto
request = request_ptr.lock() ) {
14
assert( request );
15
return
std::make_shared<EntryEvent>(request->token);
16
}
17
}
18
return
nullptr
;
19
}
20
EntryEvent.h
InstantEntry.h
BPMNOS::Execution::InstantEntry::InstantEntry
InstantEntry()
Definition
InstantEntry.cpp:7
BPMNOS::Execution::InstantEntry::dispatchEvent
std::shared_ptr< Event > dispatchEvent(const SystemState *systemState) override
Definition
InstantEntry.cpp:11
BPMNOS::Execution::SystemState
A class representing the state that the execution or simulation of a given scenario is in.
Definition
SystemState.h:21
BPMNOS::Execution::SystemState::pendingEntryDecisions
auto_list< std::weak_ptr< Token >, std::weak_ptr< DecisionRequest > > pendingEntryDecisions
Definition
SystemState.h:71
BPMNOS::Execution
Definition
Controller.h:9