* $op = 5; * $mul = new ezcWorkflowNodeVariableMul ( * array ( 'name' = > 'wfVar' , 'operand' = > $op ) * ); * * If the operand is a string, the value of the workflow variable identified by that string is used. * * Incoming nodes: 1 * Outgoing nodes: 1 * * @package Workflow * @version 1.1rc1 */ class ezcWorkflowNodeVariableMul extends ezcWorkflowNodeArithmeticBase { /** * Perform variable modification. */ protected function doExecute() { $this->variable *= $this->operand; } /** * Generate node configuration from XML representation. * * @param DOMElement $element */ public static function configurationFromXML( DOMElement $element ) { return array( 'name' => $element->getAttribute( 'variable' ), 'operand' => $element->getAttribute( 'operand' ) ); } /** * Generate XML representation of this node's configuration. * * @param DOMElement $element */ public function configurationToXML( DOMElement $element ) { $element->setAttribute( 'variable', $this->configuration['name'] ); $element->setAttribute( 'operand', $this->configuration['operand'] ); } /** * Returns a textual representation of this node. * * @return string * @ignore */ public function __toString() { return $this->configuration['name'] . ' *= ' . $this->configuration['operand']; } } ?>