Exponential 6.0.13 Exponential Enterprise Open Source CMS - PHP Class Reference

eztemplatenodetool.php
Go to the documentation of this file.
1 <?php
18 class eZTemplateNodeTool
19 {
24 static function removeFunctionNodeChildren( &$node )
25 {
26 $node[1] = false;
27 }
28
33 static function removeFunctionNodeParameters( &$node )
34 {
35 $node[3] = false;
36 }
37
42 static function removeFunctionNodePlacement( &$node )
43 {
44 $node[4] = false;
45 }
46
51 static function createVoidElement()
52 {
53 return array( eZTemplate::TYPE_VOID );
54 }
55
61 static function createConstantElement( $constant, $variablePlacement = false )
62 {
63 if ( is_array( $constant ) )
64 return eZTemplateNodeTool::createArrayElement( $constant, $variablePlacement );
65 else if ( is_string( $constant ) )
66 return eZTemplateNodeTool::createStringElement( $constant, $variablePlacement );
67 else if ( is_bool( $constant ) )
68 return eZTemplateNodeTool::createBooleanElement( $constant, $variablePlacement );
69 else if ( is_numeric( $constant ) )
70 return eZTemplateNodeTool::createNumericElement( $constant, $variablePlacement );
71 else
72 return eZTemplateNodeTool::createVoidElement();
73 }
74
79 static function createStringElement( $string, $variablePlacement = false )
80 {
81 return array( eZTemplate::TYPE_STRING,
82 $string, $variablePlacement );
83 }
84
89 static function createNumericElement( $number, $variablePlacement = false )
90 {
91 return array( eZTemplate::TYPE_NUMERIC,
92 $number, $variablePlacement );
93 }
94
99 static function createIdentifierElement( $identifier, $variablePlacement = false )
100 {
101 return array( eZTemplate::TYPE_IDENTIFIER,
102 $identifier, $variablePlacement );
103 }
104
113 static function createDynamicArrayElement( &$arrayKeys, &$arrayValues, $variablePlacement = false )
114 {
115 return array( eZTemplate::TYPE_DYNAMIC_ARRAY,
116 $arrayKeys, $arrayValues, $variablePlacement );
117 }
118
123 static function createArrayElement( $array, $variablePlacement = false )
124 {
125 return array( eZTemplate::TYPE_ARRAY,
126 $array, $variablePlacement );
127 }
128
133 static function createBooleanElement( $boolean, $variablePlacement = false )
134 {
135 if ( !is_bool( $boolean ) )
136 $boolean = (bool)$boolean;
137 return array( eZTemplate::TYPE_BOOLEAN,
138 $boolean, $variablePlacement );
139 }
140
145 static function createPHPVariableElement( $variableName, $variablePlacement = false )
146 {
147 return array( eZTemplate::TYPE_PHP_VARIABLE,
148 $variableName, $variablePlacement );
149 }
150
159 static function createVariableElement( $variableName, $namespaceName, $namespaceScope = eZTemplate::NAMESPACE_SCOPE_LOCAL, $variablePlacement = false )
160 {
161 return array( eZTemplate::TYPE_VARIABLE,
162 array( $namespaceName, $namespaceScope, $variableName ), $variablePlacement );
163 }
164
170 static function createAttributeLookupElement( $attributeValues = array(), $variablePlacement = false )
171 {
172 if ( is_numeric( $attributeValues ) )
173 $attributeValues = array( eZTemplateNodeTool::createNumericElement( $attributeValues, $variablePlacement ) );
174 else if ( !is_array( $attributeValues ) )
175 $attributeValues = array( eZTemplateNodeTool::createStringElement( $attributeValues, $variablePlacement ) );
176 return array( eZTemplate::TYPE_ATTRIBUTE,
177 $attributeValues, $variablePlacement );
178 }
179
186 static function createOperatorElement( $name, $parameters = array(), $variablePlacement = false )
187 {
188 return array( eZTemplate::TYPE_ATTRIBUTE,
189 array_merge( array( $name ), $parameters ), $variablePlacement );
190 }
191
197 static function elementConstantValue( $elements )
198 {
199 if ( eZTemplateNodeTool::isConstantElement( $elements ) or
200 eZTemplateNodeTool::isPHPVariableElement( $elements ) )
201 return $elements[0][1];
202 return null;
203 }
204
208 static function elementDynamicArrayKeys( $elements )
209 {
210 if ( !eZTemplateNodeTool::isDynamicArrayElement( $elements ) )
211 return null;
212 return $elements[0][1];
213 }
214
218 static function elementDynamicArray( $elements )
219 {
220 if ( !eZTemplateNodeTool::isDynamicArrayElement( $elements ) )
221 return null;
222 return $elements[0][2];
223 }
224
225
233 static function isConstantElement( $elements )
234 {
235 if ( !isset( $elements[0][0] ) || count( $elements ) > 1 )
236 {
237 return false;
238 }
239
240 switch ( $elements[0][0] )
241 {
242 case eZTemplate::TYPE_VOID:
243 case eZTemplate::TYPE_STRING:
244 case eZTemplate::TYPE_IDENTIFIER:
245 case eZTemplate::TYPE_NUMERIC:
246 case eZTemplate::TYPE_BOOLEAN:
247 case eZTemplate::TYPE_ARRAY:
248 return true;
249 }
250
251 return false;
252 }
253
257 static function isInternalCodePiece( $elements )
258 {
259 return isset( $elements[0][0]) && $elements[0][0] == eZTemplate::TYPE_INTERNAL_CODE_PIECE;
260 }
261
265 static function isVariableElement( $elements )
266 {
267 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_VARIABLE;
268 }
269
277 static function isPHPVariableElement( $elements )
278 {
279 if( is_null( $elements ) )
280 {
281 $elements = array();
282 }
283 return count( $elements ) === 1 && isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_PHP_VARIABLE;
284 }
285
296 static function isNumericElement( $elements )
297 {
298 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_NUMERIC;
299 }
300
311 static function isStringElement( $elements )
312 {
313 if ( !isset( $elements[0][0] ) )
314 {
315 return false;
316 }
317
318 switch ( $elements[0][0] )
319 {
320 case eZTemplate::TYPE_STRING:
321 case eZTemplate::TYPE_IDENTIFIER:
322 return true;
323 }
324
325 return false;
326 }
327
337 static function isIdentifierElement( $elements )
338 {
339 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_IDENTIFIER;
340 }
341
352 static function isBooleanElement( $elements )
353 {
354 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_BOOLEAN;
355 }
356
361 static function isDynamicArrayElement( $elements )
362 {
363 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_DYNAMIC_ARRAY;
364 }
365
374 static function isArrayElement( $elements )
375 {
376 return isset( $elements[0][0] ) && $elements[0][0] == eZTemplate::TYPE_ARRAY;
377 }
378
384 static function createFunctionNodeHook( &$node, $hookName, $hookParameters = array(), $hookFunction = false )
385 {
386 $node[5] = array( 'name' => $hookName,
387 'parameters' => $hookParameters,
388 'function' => $hookFunction );
389 }
390
395 static function createVariableNode( $originalNode = false, $variableData = false, $variablePlacement = false,
396 $parameters = array(), $variableAssignmentName = false, $onlyExisting = false,
397 $overWrite = true, $assignFromVariable = false, $rememberSet = false )
398 {
399 $node = array();
400 if ( $originalNode )
401 $node = $originalNode;
402 else
403 {
404 $node[0] = eZTemplate::NODE_VARIABLE;
405 $node[1] = $variableAssignmentName;
406 if ( is_array( $variableData ) )
407 $node[2] = $variableData;
408 else if ( $assignFromVariable )
409 $node[2] = array( array( eZTemplate::TYPE_PHP_VARIABLE,
410 $variableData,
411 false ) );
412 else if ( is_bool( $variableData ) )
413 $node[2] = array( array( eZTemplate::TYPE_BOOLEAN,
414 $variableData,
415 false ) );
416 else if ( is_string( $variableData ) )
417 $node[2] = array( array( eZTemplate::TYPE_STRING,
418 $variableData,
419 false ) );
420 else if ( is_numeric( $variableData ) )
421 $node[2] = array( array( eZTemplate::TYPE_NUMERIC,
422 $variableData,
423 false ) );
424 else
425 $node[2] = array( array( eZTemplate::TYPE_STRING,
426 $variableData,
427 false ) );
428 $node[3] = $variablePlacement;
429 }
430 $node[4] = $parameters;
431 $node[5] = $onlyExisting;
432 $node[6] = $overWrite;
433 $node[7] = $rememberSet;
434 return $node;
435 }
436
437 static function createCodePieceElement( $codePiece, $values = false, $placement = false, $tmpValues = false, $knownTypes = true )
438 {
439 return array( eZTemplate::TYPE_INTERNAL_CODE_PIECE, $codePiece, $placement, $values, $tmpValues, $knownTypes );
440 }
441
442 static function createTextNode( $text )
443 {
444 return array( eZTemplate::NODE_TEXT, false, $text, false );
445 }
446
447 static function createWarningNode( $text, $label, $placement = false, $parameters = array() )
448 {
449 return array( eZTemplate::NODE_INTERNAL_WARNING, $text, $label, $parameters, $placement );
450 }
451
452 static function createErrorNode( $text, $label, $placement = false, $parameters = array() )
453 {
454 return array( eZTemplate::NODE_INTERNAL_ERROR, $text, $label, $parameters, $placement );
455 }
456
457 static function createCodePieceNode( $codePiece, $parameters = array() )
458 {
459 return array( eZTemplate::NODE_INTERNAL_CODE_PIECE, $codePiece, $parameters );
460 }
461
462 static function createVariableUnsetNode( $variableName, $parameters = array() )
463 {
464 return array( eZTemplate::NODE_INTERNAL_VARIABLE_UNSET, $variableName, $parameters );
465 }
466
475 static function createWriteToOutputVariableNode( $variableName, $parameters = array(), $assignmentType = eZPHPCreator::VARIABLE_APPEND_TEXT )
476 {
477 return array( eZTemplate::NODE_INTERNAL_OUTPUT_ASSIGN, $variableName, $parameters, $assignmentType );
478 }
479
488 static function createAssignFromOutputVariableNode( $variableName, $parameters = array(), $assignmentType = eZPHPCreator::VARIABLE_ASSIGNMENT )
489 {
490 return array( eZTemplate::NODE_INTERNAL_OUTPUT_READ, $variableName, $parameters, $assignmentType );
491 }
492
493 static function createOutputVariableIncreaseNode( $parameters = array() )
494 {
495 return array( eZTemplate::NODE_INTERNAL_OUTPUT_INCREASE, $parameters );
496 }
497
498 static function createOutputVariableDecreaseNode( $parameters = array() )
499 {
500 return array( eZTemplate::NODE_INTERNAL_OUTPUT_DECREASE, $parameters );
501 }
502
503 static function createSpacingIncreaseNode( $spacing = 4, $parameters = array() )
504 {
505 return array( eZTemplate::NODE_INTERNAL_OUTPUT_SPACING_INCREASE, $spacing, $parameters );
506 }
507
508 static function createSpacingDecreaseNode( $spacing = 4, $parameters = array() )
509 {
510 return array( eZTemplate::NODE_INTERNAL_SPACING_DECREASE, $spacing, $parameters );
511 }
512
513 static function createNamespaceChangeNode( $variableData, $parameters = array() )
514 {
515 if ( is_string( $variableData ) )
516 $variableData = array( eZTemplateNodeTool::createStringElement( $variableData ) );
517 else if ( is_numeric( $variableData ) )
518 $variableData = array( eZTemplateNodeTool::createNumericElement( $variableData ) );
519 return array( eZTemplate::NODE_INTERNAL_NAMESPACE_CHANGE, $variableData, $parameters );
520 }
521
522 static function createNamespaceRestoreNode( $parameters = array() )
523 {
524 return array( eZTemplate::NODE_INTERNAL_NAMESPACE_RESTORE, $parameters );
525 }
526
527 static function createResourceAcquisitionNode( $resourceName, $templateName, $fileName,
528 $method, $extraParameters, $placement = false,
529 $parameters = array(), $newRootNamespace = false, $resourceVariableName = false )
530 {
531 $node = array( eZTemplate::NODE_INTERNAL_RESOURCE_ACQUISITION,
532 $resourceName, $templateName, $fileName,
533 $method, $extraParameters, $placement );
534 if ( count( $parameters ) > 0 )
535 $node[] = $parameters;
536 else
537 $node[] = false;
538 $node[] = $newRootNamespace;
539 $node[] = $resourceVariableName;
540 return $node;
541 }
542
543 static function extractNodes( $nodeList, $parameters = array() )
544 {
545 $match = false;
546 if ( isset( $parameters['match'] ) )
547 $match = $parameters['match'];
548 $newNodes = array();
549 $skipNode = false;
550 if ( $match['type'] == 'after' )
551 $skipNode = true;
552
553 if ( !is_array( $nodeList ) )
554 {
555 return $newNodes;
556 }
557 foreach ( $nodeList as $node )
558 {
559 if ( $match )
560 {
561 $isMatch = true;
562 foreach ( $match['matches'] as $matchItem )
563 {
564 $operand1 = $matchItem['match-with'];
565 $matchKeys = $matchItem['match-keys'];
566 $operand2 = $node;
567 foreach ( $matchKeys as $matchKey )
568 {
569 $operand2 = $operand2[$matchKey];
570 }
571 if ( isset( $matchItem['match-function'] ) )
572 {
573 $function = $matchItem['match-function'];
574 $functionResult = $function( $operand1, $operand2 );
575 $wasMatch = $functionResult == 0;
576 }
577 else
578 {
579 if ( is_array( $operand1 ) )
580 $wasMatch = in_array( $operand2, $operand1 );
581 else
582 $wasMatch = ( $operand1 == $operand2 );
583 }
584 if ( !$wasMatch )
585 {
586 $isMatch = false;
587 break;
588 }
589 }
590 if ( $match['type'] == 'equal' )
591 {
592 if ( !$isMatch )
593 continue;
594 }
595 else if ( $match['type'] == 'before' )
596 {
597 if ( $isMatch )
598 break;
599 }
600 else if ( $match['type'] = 'after' )
601 {
602 if ( $isMatch )
603 {
604 $skipNode = false;
605 $match = false;
606 continue;
607 }
608 }
609 }
610 if ( $skipNode )
611 continue;
612 if ( $match and isset( $match['filter'] ) )
613 {
614 $isMatch = true;
615 foreach ( $match['filter'] as $matchFilterItem )
616 {
617 foreach ( $matchFilterItem as $matchItem )
618 {
619 $operand1 = $matchItem['match-with'];
620 $matchKeys = $matchItem['match-keys'];
621 $operand2 = $node;
622 foreach ( $matchKeys as $matchKey )
623 {
624 $operand2 = $operand2[$matchKey];
625 }
626 if ( isset( $matchItem['match-function'] ) )
627 {
628 $function = $matchItem['match-function'];
629 $functionResult = $function( $operand1, $operand2 );
630 $wasMatch = $functionResult == 0;
631 }
632 else
633 {
634 if ( is_array( $operand1 ) )
635 $wasMatch = in_array( $operand2, $operand1 );
636 else
637 $wasMatch = ( $operand1 == $operand2 );
638 }
639 if ( !$wasMatch )
640 {
641 $isMatch = false;
642 break;
643 }
644 }
645 if ( $isMatch )
646 break;
647 }
648 if ( $isMatch )
649 continue;
650 }
651 $newNodes[] = $node;
652 }
653 return $newNodes;
654 }
655
660 static function extractFunctionNodePlacement( &$node )
661 {
662 return $node[4];
663 }
664
669 static function extractFunctionNodeChildren( &$node )
670 {
671 return $node[1];
672 }
673
678 static function extractFunctionNodeParameters( &$node )
679 {
680 return $node[3];
681 }
682
687 static function extractFunctionNodeParameterNames( &$node )
688 {
689 return array_keys( $node[3] );
690 }
691
696 static function extractVariableNodeData( &$node )
697 {
698 return $node[1];
699 }
700
705 static function extractFunctionNodeName( &$node )
706 {
707 return $node[2];
708 }
709
714 static function extractVariableNodePlacement( &$node )
715 {
716 return $node[2];
717 }
718
723 static function extractOperatorNodeParameters( &$node )
724 {
725 return array_slice( $node[1], 1 );
726 }
727
734 static function deflateFunctionNode( &$node, $preHook, $postHook )
735 {
736 $newNodes = array();
737 $children = eZTemplateNodeTool::extractFunctionNodeChildren( $node );
738 eZTemplateNodeTool::removeFunctionNodeChildren( $node );
739 $preNode = $node;
740 $preHookParameters = array();
741 if ( isset( $preHook['parameters'] ) )
742 $preHookParameters = $preHook['parameters'];
743 $preHookFunction = false;
744 if ( isset( $preHook['function'] ) )
745 $preHookFunction = $preHook['function'];
746 eZTemplateNodeTool::createFunctionNodeHook( $preNode, $preHook['name'], $preHookParameters, $preHookFunction );
747 if ( isset( $preHook['use-parameters'] ) and
748 !$preHook['use-parameters'] )
749 eZTemplateNodeTool::removeFunctionNodeParameters( $preNode );
750 $newNodes[] = $preNode;
751 $newNodes = array_merge( $newNodes, $children );
752 $postNode = $node;
753 $postHookParameters = array();
754 if ( isset( $postHook['parameters'] ) )
755 $postHookParameters = $postHook['parameters'];
756 $postHookFunction = false;
757 if ( isset( $postHook['function'] ) )
758 $postHookFunction = $postHook['function'];
759 eZTemplateNodeTool::createFunctionNodeHook( $postNode, $postHook['name'], $postHookParameters, $postHookFunction );
760 if ( isset( $postHook['use-parameters'] ) and
761 !$postHook['use-parameters'] )
762 eZTemplateNodeTool::removeFunctionNodeParameters( $postNode );
763 $newNodes[] = $postNode;
764 return $newNodes;
765 }
766 }
767
768 ?>
eZTemplateNodeTool
Various tool functions for working with template nodes.
Definition: eztemplatenodetool.php:19
eZTemplateNodeTool\isVariableElement
static isVariableElement( $elements)
Definition: eztemplatenodetool.php:265
eZTemplateNodeTool\createVariableNode
static createVariableNode( $originalNode=false, $variableData=false, $variablePlacement=false, $parameters=array(), $variableAssignmentName=false, $onlyExisting=false, $overWrite=true, $assignFromVariable=false, $rememberSet=false)
Definition: eztemplatenodetool.php:395
eZTemplateNodeTool\createWriteToOutputVariableNode
static createWriteToOutputVariableNode( $variableName, $parameters=array(), $assignmentType=eZPHPCreator::VARIABLE_APPEND_TEXT)
Definition: eztemplatenodetool.php:475
eZTemplateNodeTool\isIdentifierElement
static isIdentifierElement( $elements)
Definition: eztemplatenodetool.php:337
eZTemplateNodeTool\elementConstantValue
static elementConstantValue( $elements)
Definition: eztemplatenodetool.php:197
eZTemplateNodeTool\isStringElement
static isStringElement( $elements)
Definition: eztemplatenodetool.php:311
eZTemplateNodeTool\createPHPVariableElement
static createPHPVariableElement( $variableName, $variablePlacement=false)
Definition: eztemplatenodetool.php:145
eZTemplateNodeTool\extractNodes
static extractNodes( $nodeList, $parameters=array())
Definition: eztemplatenodetool.php:543
eZTemplateNodeTool\isDynamicArrayElement
static isDynamicArrayElement( $elements)
Definition: eztemplatenodetool.php:361
eZTemplateNodeTool\removeFunctionNodeParameters
static removeFunctionNodeParameters(&$node)
Definition: eztemplatenodetool.php:33
eZTemplateNodeTool\createCodePieceElement
static createCodePieceElement( $codePiece, $values=false, $placement=false, $tmpValues=false, $knownTypes=true)
Definition: eztemplatenodetool.php:437
eZTemplateNodeTool\createFunctionNodeHook
static createFunctionNodeHook(&$node, $hookName, $hookParameters=array(), $hookFunction=false)
Definition: eztemplatenodetool.php:384
eZTemplateNodeTool\elementDynamicArrayKeys
static elementDynamicArrayKeys( $elements)
Definition: eztemplatenodetool.php:208
eZTemplateNodeTool\removeFunctionNodeChildren
static removeFunctionNodeChildren(&$node)
Definition: eztemplatenodetool.php:24
eZTemplateNodeTool\createSpacingDecreaseNode
static createSpacingDecreaseNode( $spacing=4, $parameters=array())
Definition: eztemplatenodetool.php:508
eZTemplateNodeTool\isPHPVariableElement
static isPHPVariableElement( $elements)
Definition: eztemplatenodetool.php:277
eZTemplateNodeTool\elementDynamicArray
static elementDynamicArray( $elements)
Definition: eztemplatenodetool.php:218
eZTemplateNodeTool\extractVariableNodeData
static extractVariableNodeData(&$node)
Definition: eztemplatenodetool.php:696
eZTemplateNodeTool\deflateFunctionNode
static deflateFunctionNode(&$node, $preHook, $postHook)
Definition: eztemplatenodetool.php:734
eZTemplateNodeTool\createNumericElement
static createNumericElement( $number, $variablePlacement=false)
Definition: eztemplatenodetool.php:89
eZTemplateNodeTool\createOperatorElement
static createOperatorElement( $name, $parameters=array(), $variablePlacement=false)
Definition: eztemplatenodetool.php:186
eZTemplateNodeTool\extractOperatorNodeParameters
static extractOperatorNodeParameters(&$node)
Definition: eztemplatenodetool.php:723
eZTemplateNodeTool\extractFunctionNodeParameterNames
static extractFunctionNodeParameterNames(&$node)
Definition: eztemplatenodetool.php:687
eZTemplateNodeTool\createVariableUnsetNode
static createVariableUnsetNode( $variableName, $parameters=array())
Definition: eztemplatenodetool.php:462
eZTemplateNodeTool\createCodePieceNode
static createCodePieceNode( $codePiece, $parameters=array())
Definition: eztemplatenodetool.php:457
eZTemplateNodeTool\createConstantElement
static createConstantElement( $constant, $variablePlacement=false)
Definition: eztemplatenodetool.php:61
eZTemplateNodeTool\removeFunctionNodePlacement
static removeFunctionNodePlacement(&$node)
Definition: eztemplatenodetool.php:42
eZTemplateNodeTool\createSpacingIncreaseNode
static createSpacingIncreaseNode( $spacing=4, $parameters=array())
Definition: eztemplatenodetool.php:503
eZTemplateNodeTool\createNamespaceRestoreNode
static createNamespaceRestoreNode( $parameters=array())
Definition: eztemplatenodetool.php:522
eZTemplateNodeTool\createBooleanElement
static createBooleanElement( $boolean, $variablePlacement=false)
Definition: eztemplatenodetool.php:133
eZTemplateNodeTool\createOutputVariableIncreaseNode
static createOutputVariableIncreaseNode( $parameters=array())
Definition: eztemplatenodetool.php:493
eZTemplateNodeTool\createTextNode
static createTextNode( $text)
Definition: eztemplatenodetool.php:442
eZTemplateNodeTool\extractVariableNodePlacement
static extractVariableNodePlacement(&$node)
Definition: eztemplatenodetool.php:714
eZTemplateNodeTool\createNamespaceChangeNode
static createNamespaceChangeNode( $variableData, $parameters=array())
Definition: eztemplatenodetool.php:513
eZTemplateNodeTool\createVoidElement
static createVoidElement()
Definition: eztemplatenodetool.php:51
eZTemplateNodeTool\createAttributeLookupElement
static createAttributeLookupElement( $attributeValues=array(), $variablePlacement=false)
Definition: eztemplatenodetool.php:170
eZTemplateNodeTool\extractFunctionNodePlacement
static extractFunctionNodePlacement(&$node)
Definition: eztemplatenodetool.php:660
eZTemplateNodeTool\createIdentifierElement
static createIdentifierElement( $identifier, $variablePlacement=false)
Definition: eztemplatenodetool.php:99
eZTemplateNodeTool\extractFunctionNodeParameters
static extractFunctionNodeParameters(&$node)
Definition: eztemplatenodetool.php:678
eZTemplateNodeTool\isBooleanElement
static isBooleanElement( $elements)
Definition: eztemplatenodetool.php:352
eZTemplateNodeTool\isArrayElement
static isArrayElement( $elements)
Definition: eztemplatenodetool.php:374
eZTemplateNodeTool\createResourceAcquisitionNode
static createResourceAcquisitionNode( $resourceName, $templateName, $fileName, $method, $extraParameters, $placement=false, $parameters=array(), $newRootNamespace=false, $resourceVariableName=false)
Definition: eztemplatenodetool.php:527
eZTemplateNodeTool\createOutputVariableDecreaseNode
static createOutputVariableDecreaseNode( $parameters=array())
Definition: eztemplatenodetool.php:498
eZTemplateNodeTool\isNumericElement
static isNumericElement( $elements)
Definition: eztemplatenodetool.php:296
eZTemplateNodeTool\createWarningNode
static createWarningNode( $text, $label, $placement=false, $parameters=array())
Definition: eztemplatenodetool.php:447
eZTemplateNodeTool\isInternalCodePiece
static isInternalCodePiece( $elements)
Definition: eztemplatenodetool.php:257
eZTemplateNodeTool\createStringElement
static createStringElement( $string, $variablePlacement=false)
Definition: eztemplatenodetool.php:79
eZTemplateNodeTool\createVariableElement
static createVariableElement( $variableName, $namespaceName, $namespaceScope=eZTemplate::NAMESPACE_SCOPE_LOCAL, $variablePlacement=false)
Definition: eztemplatenodetool.php:159
eZTemplateNodeTool\createArrayElement
static createArrayElement( $array, $variablePlacement=false)
Definition: eztemplatenodetool.php:123
eZTemplateNodeTool\createErrorNode
static createErrorNode( $text, $label, $placement=false, $parameters=array())
Definition: eztemplatenodetool.php:452
eZTemplateNodeTool\createAssignFromOutputVariableNode
static createAssignFromOutputVariableNode( $variableName, $parameters=array(), $assignmentType=eZPHPCreator::VARIABLE_ASSIGNMENT)
Definition: eztemplatenodetool.php:488
eZTemplateNodeTool\createDynamicArrayElement
static createDynamicArrayElement(&$arrayKeys, &$arrayValues, $variablePlacement=false)
Definition: eztemplatenodetool.php:113
eZTemplateNodeTool\extractFunctionNodeName
static extractFunctionNodeName(&$node)
Definition: eztemplatenodetool.php:705
eZTemplateNodeTool\extractFunctionNodeChildren
static extractFunctionNodeChildren(&$node)
Definition: eztemplatenodetool.php:669
eZTemplateNodeTool\isConstantElement
static isConstantElement( $elements)
Definition: eztemplatenodetool.php:233
eZTemplate\NODE_INTERNAL_WARNING
const NODE_INTERNAL_WARNING
Definition: eztemplate.php:226
eZTemplate\NODE_INTERNAL_VARIABLE_UNSET
const NODE_INTERNAL_VARIABLE_UNSET
Definition: eztemplate.php:221
eZTemplate\NODE_INTERNAL_RESOURCE_ACQUISITION
const NODE_INTERNAL_RESOURCE_ACQUISITION
Definition: eztemplate.php:229
eZTemplate\TYPE_DYNAMIC_ARRAY
const TYPE_DYNAMIC_ARRAY
Definition: eztemplate.php:255
eZTemplate\TYPE_VARIABLE
const TYPE_VARIABLE
Definition: eztemplate.php:250
eZTemplate\NODE_INTERNAL_SPACING_DECREASE
const NODE_INTERNAL_SPACING_DECREASE
Definition: eztemplate.php:238
eZTemplate\NODE_INTERNAL_CODE_PIECE
const NODE_INTERNAL_CODE_PIECE
Definition: eztemplate.php:218
eZTemplate\NODE_INTERNAL_OUTPUT_ASSIGN
const NODE_INTERNAL_OUTPUT_ASSIGN
Definition: eztemplate.php:232
eZTemplate\NAMESPACE_SCOPE_LOCAL
const NAMESPACE_SCOPE_LOCAL
Definition: eztemplate.php:285
eZTemplate\TYPE_PHP_VARIABLE
const TYPE_PHP_VARIABLE
Definition: eztemplate.php:259
eZTemplate\NODE_TEXT
const NODE_TEXT
Definition: eztemplate.php:211
eZTemplate\NODE_INTERNAL_NAMESPACE_CHANGE
const NODE_INTERNAL_NAMESPACE_CHANGE
Definition: eztemplate.php:223
eZTemplate\TYPE_ARRAY
const TYPE_ARRAY
Definition: eztemplate.php:254
eZTemplate\TYPE_BOOLEAN
const TYPE_BOOLEAN
Definition: eztemplate.php:253
eZTemplate\TYPE_INTERNAL_CODE_PIECE
const TYPE_INTERNAL_CODE_PIECE
Definition: eztemplate.php:258
eZTemplate\NODE_VARIABLE
const NODE_VARIABLE
Definition: eztemplate.php:212
eZTemplate\NODE_INTERNAL_OUTPUT_READ
const NODE_INTERNAL_OUTPUT_READ
Definition: eztemplate.php:233
eZTemplate\TYPE_ATTRIBUTE
const TYPE_ATTRIBUTE
Definition: eztemplate.php:251
eZTemplate\TYPE_VOID
const TYPE_VOID
Definition: eztemplate.php:246
eZTemplate\TYPE_IDENTIFIER
const TYPE_IDENTIFIER
Definition: eztemplate.php:249
eZTemplate\NODE_INTERNAL_NAMESPACE_RESTORE
const NODE_INTERNAL_NAMESPACE_RESTORE
Definition: eztemplate.php:224
eZTemplate\NODE_INTERNAL_ERROR
const NODE_INTERNAL_ERROR
Definition: eztemplate.php:227
eZTemplate\TYPE_NUMERIC
const TYPE_NUMERIC
Definition: eztemplate.php:248
eZTemplate\TYPE_STRING
const TYPE_STRING
Definition: eztemplate.php:247
eZTemplate\NODE_INTERNAL_OUTPUT_DECREASE
const NODE_INTERNAL_OUTPUT_DECREASE
Definition: eztemplate.php:235
eZTemplate\NODE_INTERNAL_OUTPUT_INCREASE
const NODE_INTERNAL_OUTPUT_INCREASE
Definition: eztemplate.php:234
eZTemplate\NODE_INTERNAL_OUTPUT_SPACING_INCREASE
const NODE_INTERNAL_OUTPUT_SPACING_INCREASE
Definition: eztemplate.php:237
Copyright © 1998 – 2026 7x. All rights reserved. Licensed under the GNU GPLv2+.