BPMN-OS
BPMN for optimization and simulation
Loading...
Searching...
No Matches
BPMNOS::Execution::FlattenedGraph Class Reference

Represents a graph containing all BPMN nodes that may receive a token during execution of a scenario. More...

Detailed Description

For a given scenario, the FlattenedGraph class encapsulates a graph containing a vertex for each entry and each exit of a node in a BPMN model. The flattened graph includes all instances known at time zero.

Definition at line 23 of file FlattenedGraph.h.

#include <FlattenedGraph.h>

Classes

class  Vertex
 

Public Member Functions

 FlattenedGraph (const BPMNOS::Model::Scenario *scenario)
 
nlohmann::ordered_json jsonify () const
 
std::vector< const Vertex * > sortVertices () const
 Container holding entry vertices of all process instances.
 
const BPMNOS::Model::AttributegetLoopIndexAttribute (const BPMN::Activity *activity) const
 Container holding dummy vertices for loop & multi-instance activities.
 
void addInstance (const BPMNOS::Model::Scenario::InstanceData *instance)
 Map holding entry and exit vertices of each possible instantiation of a node.
 
bool modifiesData (const Vertex *vertex, const Vertex *dataOwner) const
 Container holding vertices of tasks modifying global attributes.
 
bool modifiesGlobals (const Vertex *vertex) const
 Method returning true if the vertex modifies a data attribute of the given owner.
 
const VertexgetVertex (const Token *token) const
 Method returning true if the vertex modifies a global attribute.
 
const Vertexentry (const Vertex *vertex) const
 
const Vertexexit (const Vertex *vertex) const
 

Public Attributes

const BPMNOS::Model::Scenarioscenario
 
std::vector< const Vertex * > initialVertices
 
std::vector< std::unique_ptr< Vertex > > vertices
 Returns a topologically sorted vector of all vertices reachable from the initial vertices.
 
std::unordered_set< const Vertex * > dummies
 Container holding entry and exit vertices of each possible instantiation of a node.
 
std::unordered_map< const BPMN::Node *, std::vector< const BPMNOS::Model::Attribute * > > loopIndexAttributes
 
tuple_map< std::tuple< BPMNOS::number, std::vector< size_t >, const BPMN::Node * >, std::pair< Vertex *, Vertex * > > vertexMap
 
std::unordered_map< const Vertex *, std::vector< std::pair< const Vertex *, const Vertex * > > > sequentialActivities
 
std::unordered_map< const Vertex *, std::vector< std::pair< const Vertex *, const Vertex * > > > dataModifiers
 Container allowing to look up vertices of sequential activities given a pointer to the entry vertex of a performer

 
std::vector< std::pair< const Vertex *, const Vertex * > > globalModifiers
 Container allowing to look up vertices of tasks modifying data attributes given a pointer to the entry vertex of the node owning the data.
 

Constructor & Destructor Documentation

◆ FlattenedGraph()

FlattenedGraph::FlattenedGraph ( const BPMNOS::Model::Scenario * scenario)

Definition at line 119 of file FlattenedGraph.cpp.

Member Function Documentation

◆ addInstance()

void FlattenedGraph::addInstance ( const BPMNOS::Model::Scenario::InstanceData * instance)

Definition at line 136 of file FlattenedGraph.cpp.

◆ entry()

const FlattenedGraph::Vertex * FlattenedGraph::entry ( const Vertex * vertex) const

Definition at line 744 of file FlattenedGraph.cpp.

◆ exit()

const FlattenedGraph::Vertex * FlattenedGraph::exit ( const Vertex * vertex) const

Definition at line 748 of file FlattenedGraph.cpp.

◆ getLoopIndexAttribute()

const BPMNOS::Model::Attribute * FlattenedGraph::getLoopIndexAttribute ( const BPMN::Activity * activity) const

Definition at line 240 of file FlattenedGraph.cpp.

◆ getVertex()

const FlattenedGraph::Vertex * FlattenedGraph::getVertex ( const Token * token) const

Definition at line 714 of file FlattenedGraph.cpp.

◆ jsonify()

nlohmann::ordered_json FlattenedGraph::jsonify ( ) const

Definition at line 128 of file FlattenedGraph.cpp.

◆ modifiesData()

bool FlattenedGraph::modifiesData ( const Vertex * vertex,
const Vertex * dataOwner ) const

Definition at line 652 of file FlattenedGraph.cpp.

◆ modifiesGlobals()

bool FlattenedGraph::modifiesGlobals ( const Vertex * vertex) const

Definition at line 659 of file FlattenedGraph.cpp.

◆ sortVertices()

std::vector< const FlattenedGraph::Vertex * > FlattenedGraph::sortVertices ( ) const

Definition at line 666 of file FlattenedGraph.cpp.

Member Data Documentation

◆ dataModifiers

std::unordered_map<const Vertex*, std::vector< std::pair<const Vertex*, const Vertex*> > > BPMNOS::Execution::FlattenedGraph::dataModifiers

Definition at line 91 of file FlattenedGraph.h.

◆ dummies

std::unordered_set< const Vertex* > BPMNOS::Execution::FlattenedGraph::dummies

Definition at line 69 of file FlattenedGraph.h.

◆ globalModifiers

std::vector< std::pair<const Vertex*, const Vertex*> > BPMNOS::Execution::FlattenedGraph::globalModifiers

Definition at line 92 of file FlattenedGraph.h.

◆ initialVertices

std::vector< const Vertex* > BPMNOS::Execution::FlattenedGraph::initialVertices

Definition at line 66 of file FlattenedGraph.h.

◆ loopIndexAttributes

std::unordered_map< const BPMN::Node*, std::vector< const BPMNOS::Model::Attribute* > > BPMNOS::Execution::FlattenedGraph::loopIndexAttributes

Definition at line 72 of file FlattenedGraph.h.

◆ scenario

const BPMNOS::Model::Scenario* BPMNOS::Execution::FlattenedGraph::scenario

Definition at line 26 of file FlattenedGraph.h.

◆ sequentialActivities

std::unordered_map<const Vertex*, std::vector< std::pair<const Vertex*, const Vertex*> > > BPMNOS::Execution::FlattenedGraph::sequentialActivities

Definition at line 90 of file FlattenedGraph.h.

◆ vertexMap

tuple_map< std::tuple<BPMNOS::number, std::vector< size_t >, const BPMN::Node* >, std::pair<Vertex*, Vertex*> > BPMNOS::Execution::FlattenedGraph::vertexMap

Definition at line 73 of file FlattenedGraph.h.

◆ vertices

std::vector< std::unique_ptr<Vertex> > BPMNOS::Execution::FlattenedGraph::vertices

Definition at line 68 of file FlattenedGraph.h.


The documentation for this class was generated from the following files: