PHP Класс ezcWorkflowNodeInput, Workflow
When the node is reached, the workflow engine will suspend the workflow execution if the
specified input data is not available (first activation). While the workflow is suspended,
the application that embeds the workflow engine may supply the input data and resume the workflow
execution (second activation of the input node). Input data is stored in a workflow variable.
Incoming nodes: 1
Outgoing nodes: 1
This example creates a simple workflow that expectes two input variables,
once which can be any value and another that can only be an integer between
one and ten.
new ezcWorkflowConditionIsAnything,
'intVar' => new ezcWorkflowConditionAnd(
array(
new ezcWorkflowConditionIsInteger,
new ezcWorkflowConditionIsGreatherThan( 0 )
new ezcWorkflowConditionIsLessThan( 11 )
)
)
);
$input->addOutNode( $workflow->endNode );
$workflow->startNode->addOutNode( $input );
?>
Показать файл
Открыть проект
Примеры использования класса
Открытые методы
Метод |
Описание |
|
__construct ( mixed $configuration = '' ) |
Constructs a new input node. |
|
configurationFromXML ( DOMElement $element ) : array |
Generate node configuration from XML representation. |
|
configurationToXML ( DOMElement $element ) |
Generate XML representation of this node's configuration. |
|
execute ( ezcWorkflowExecution $execution ) : boolean |
Executes this node. |
|
Описание методов
__construct()
публичный Метод
An input node accepts an array of workflow variables to accept
and/or together with a condition on the variable if required.
Each element in the configuration array must be either
String: The name of the workflow variable to require. No conditions.
or
- Key: The name of the workflow variable to require.
- Value: An object of type ezcWorkflowCondition
configurationFromXML()
публичный статический Метод
Generate node configuration from XML representation.
configurationToXML()
публичный Метод
Generate XML representation of this node's configuration.
execute()
публичный Метод
public execute ( ezcWorkflowExecution $execution ) : boolean |
$execution |
ezcWorkflowExecution |
|
Результат |
boolean |
true when the node finished execution,
and false otherwise |