ILIAS  release_6 Revision v6.24-5-g0c8bfefb3b8
ilBPMN2ElementLoader Class Reference

Class ilBPMN2ElementLoader. More...

+ Collaboration diagram for ilBPMN2ElementLoader:

Public Member Functions

 __construct ($bpmn2_array)
 ilBPMN2ElementLoader constructor. More...
 
 load ($element_name)
 

Protected Attributes

 $bpmn2_array
 

Detailed Description

Class ilBPMN2ElementLoader.

Author
Maximilian Becker mbeck.nosp@m.er@d.nosp@m.ataba.nosp@m.y.de
Version
$Id$

/

Definition at line 14 of file class.ilBPMN2ElementLoader.php.

Constructor & Destructor Documentation

◆ __construct()

ilBPMN2ElementLoader::__construct (   $bpmn2_array)

ilBPMN2ElementLoader constructor.

Parameters
$bpmn2_array

Definition at line 24 of file class.ilBPMN2ElementLoader.php.

25 {
26 $this->bpmn2_array = $bpmn2_array;
27 }

References $bpmn2_array.

Member Function Documentation

◆ load()

ilBPMN2ElementLoader::load (   $element_name)
Parameters
string$element_name
Returns
mixed

Definition at line 34 of file class.ilBPMN2ElementLoader.php.

35 {
36 preg_match('/[A-Z]/', $element_name, $matches, PREG_OFFSET_CAPTURE);
37 $type = strtolower(substr($element_name, @$matches[0][1]));
38 if ($type == 'basedgateway') {
39 // Fixing a violation of the standards naming convention by the standard here.
40 $type = 'gateway';
41 }
42
43 if ($type == 'objectreference') {
44 // Fixing a violation of the standards naming convention by the standard here.
45 $type = 'object';
46 }
47
48 require_once './Services/WorkflowEngine/classes/parser/elements/' . $type . '/class.il' . ucfirst($element_name) . 'Element.php';
49 $classname = 'il' . ucfirst($element_name) . 'Element';
50 $instance = new $classname;
51 $instance->setBPMN2Array($this->bpmn2_array);
52
53 return $instance;
54 }
$type

References $type.

Field Documentation

◆ $bpmn2_array

array ilBPMN2ElementLoader::$bpmn2_array
protected

Definition at line 17 of file class.ilBPMN2ElementLoader.php.

Referenced by __construct().


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