diff --git a/src/ProcessMaker/Nayra/Bpmn/LoopCharacteristicsTrait.php b/src/ProcessMaker/Nayra/Bpmn/LoopCharacteristicsTrait.php index a54dee14..37be1afb 100644 --- a/src/ProcessMaker/Nayra/Bpmn/LoopCharacteristicsTrait.php +++ b/src/ProcessMaker/Nayra/Bpmn/LoopCharacteristicsTrait.php @@ -69,7 +69,7 @@ private function setLoopInstanceProperty(TokenInterface $token, $key, $value) * * @return mixed */ - private function getLoopInstanceProperty(TokenInterface $token, $key, $defaultValue = null) + public function getLoopInstanceProperty(TokenInterface $token, $key, $defaultValue = null) { $loopCharacteristics = $token->getProperty(LoopCharacteristicsInterface::BPMN_LOOP_INSTANCE_PROPERTY, []); $outerInstance = $loopCharacteristics['sourceToken']; diff --git a/src/ProcessMaker/Nayra/Contracts/Bpmn/LoopCharacteristicsInterface.php b/src/ProcessMaker/Nayra/Contracts/Bpmn/LoopCharacteristicsInterface.php index 49a2f422..7db30741 100644 --- a/src/ProcessMaker/Nayra/Contracts/Bpmn/LoopCharacteristicsInterface.php +++ b/src/ProcessMaker/Nayra/Contracts/Bpmn/LoopCharacteristicsInterface.php @@ -83,4 +83,15 @@ public function isExecutable(); * @return void */ public function mergeOutputData(CollectionInterface $consumedTokens, ExecutionInstanceInterface $instance); + + /** + * Get Loop Instance property during execution + * + * @param TokenInterface $token + * @param string $key + * @param mixed $defaultValue + * + * @return mixed + */ + public function getLoopInstanceProperty(TokenInterface $token, $key, $defaultValue = null); }