phing-tasks-system

# Class: PhpEvalTask Source Location: /tasks/system/PhpEvalTask.php
### Class Overview
    ProjectComponent
       |
       --Task
          |
          --PhpEvalTask
Executes PHP function or evaluates expression and sets return value to a property. #### Author(s): Hans Lellelid <hans@xmpl.org> #### Version: $Revision: 557 $ #### Copyright: � 2001,2002 THYRELL. All rights reserved | ### Variables $class $expression $function $params $returnProperty | ### Methods addText callFunction createParam evalExpression main setClass setExpression setFunction setReturnProperty
### Inherited Variables #### Class: Task Task::$description Task::$location Task::$target Task::$taskName Task::$taskType Task::$wrapper #### Class: ProjectComponent ProjectComponent::$project | ### Inherited Methods #### Class: Task Task::getDescription() Returns the textual description of the task Task::getLocation() Returns the location within the buildfile this task occurs. Used by BuildException to give detailed error messages. Task::getOwningTarget() Returns the owning target of this task. Task::getRegisterSlot() Returns a name Task::getRuntimeConfigurableWrapper() Returns the wrapper object for runtime configuration Task::getTaskName() Returns the name of task, used only for log messages Task::getTaskType() Returns the name of the task under which it was invoked, usually the XML tagname Task::init() Called by the parser to let the task initialize properly. Task::log() Provides a project level log event to the task. Task::main() Called by the project to let the task do it's work. This method may be called more than once, if the task is invoked more than once. For example, if target1 and target2 both depend on target3, then running <em>phing target1 target2</em> will run all tasks in target3 twice. Task::maybeConfigure() Configure this task if it hasn't been done already. Task::perform() Perfrom this task Task::setDescription() Sets a textual description of the task Task::setLocation() Sets the location within the buildfile this task occurs. Called by the parser to set location information. Task::setOwningTarget() Sets the owning target this task belongs to. Task::setRuntimeConfigurableWrapper() Sets the wrapper object this task should use for runtime configurable elements. Task::setTaskName() Sets the name of this task for log messages Task::setTaskType() Sets the type of the task. Usually this is the name of the XML tag #### Class: ProjectComponent ProjectComponent::getProject() Returns a reference to current project ProjectComponent::log() Logs a message with the given priority. ProjectComponent::setProject() References the project to the current component.
### Class Details [line 37] Executes PHP function or evaluates expression and sets return value to a property. WARNING: This task can, of course, be abused with devastating effects. E.g. do not modify internal Phing classes unless you know what you are doing. #### Tags:
author: | Hans Lellelid <hans@xmpl.org>
version: | $Revision: 557 $
copyright: | � 2001,2002 THYRELL. All rights reserved
todo: | Add support for evaluating expressions
[ Top ] ### Class Variables #### $class = [line 41] #### Tags:
access: | protected
Type: | mixed
[ Top ] #### $expression = [line 39] #### Tags:
access: | protected
Type: | mixed
[ Top ] #### $function = [line 40] #### Tags:
access: | protected
Type: | mixed
[ Top ] #### $params = array() [line 43] #### Tags:
access: | protected
Type: | mixed
[ Top ] #### $returnProperty = [line 42] #### Tags:
access: | protected
Type: | mixed
[ Top ] ### Class Methods ### method addText [line 134]
`void addText( $expression)`
Set PHP expression to evaluate. #### Tags:
access: | public
#### Parameters:
| $expression |
[ Top ] ### method callFunction [line 76]
`mixed callFunction( )`
Calls function and returns results. #### Tags:
access: | protected
[ Top ] ### method createParam [line 144]
`void createParam( )`
Add a nested <param> tag. #### Tags:
access: | public
[ Top ] ### method evalExpression [line 108]
`mixed evalExpression( )`
Evaluates expression and returns resulting value. #### Tags:
access: | protected
[ Top ] ### method main [line 46]
`void main( )`
Main entry point. Overrides Task::main() (Called by the project to let the task do it's work. This method may be called more than once, if the task is invoked more than once. For example, if target1 and target2 both depend on target3, then running <em>phing target1 target2</em> will run all tasks in target3 twice.) [ Top ] ### method setClass [line 124]
`void setClass( $c)`
Set [static] class which contains function to execute #### Tags:
access: | public
#### Parameters:
| $c |
[ Top ] ### method setExpression [line 139]
`void setExpression( $expression)`
Set PHP expression to evaluate. #### Tags:
access: | public
#### Parameters:
| $expression |
[ Top ] ### method setFunction [line 119]
`void setFunction( $f)`
Set function to execute #### Tags:
access: | public
#### Parameters:
| $f |
[ Top ] ### method setReturnProperty [line 129]
`void setReturnProperty( $r)`
Sets property name to set with return value of function or expression. #### Tags:
access: | public
#### Parameters:
| $r |
[ Top ] Documentation generated on Mon, 19 Oct 2009 10:51:41 +0200 by phpDocumentor 1.4.3