Target.php
The Target component. Carries all required target data. Implements the abstract class {@link TaskContainer}
@author Andreas Aderhold andi@binarycloud.com
- Access
- public
- Copyright
- 2001,2002 THYRELL. All rights reserved
- Package
- phing
- See
- \TaskContainer
- Version
- $Revision: 915 $ $Date: 2010-10-12 04:30:52 +0200 (Tue, 12 Oct 2010) $
\Target
The Target component. Carries all required target data. Implements the abstract class {@link TaskContainer}
@author Andreas Aderhold andi@binarycloud.com
- Implements
- \TaskContainer
- See
- \TaskContainer
- Access
- public
- Copyright
- 2001,2002 THYRELL. All rights reserved
- Version
- $Revision: 915 $ $Date: 2010-10-12 04:30:52 +0200 (Tue, 12 Oct 2010) $
Properties

boolean
$hidden= 'false'
Whether to hide target in targets list (-list -p switches)
falseDetails- Type
- boolean
Methods

addDataType(
$rtc
)
:
voidAdds a runtime configurable element to the list of this targets child elements.
@param object The RuntimeConfigurabel object
| Name | Type | Description |
|---|---|---|
| $rtc |
- Access
- public

addDependency(
$dependency
)
:
voidAdds a singular dependent target name to the list
@param string The dependency target to add
| Name | Type | Description |
|---|---|---|
| $dependency |
- Access
- public

addTask(
$task
)
:
voidAdds a task element to the list of this targets child elements
@param object The task object to add
| Name | Type | Description |
|---|---|---|
| $task |
- Access
- public

getDependencies(
)
:
voidReturns reference to indexed array of the dependencies this target has.
@return array Referece to target dependencoes

getDescription(
)
:
voidReturns the description of this target.
@return string The description text of this target

getHidden(
)
:
booleanGet target status. If true, target does not come in phing -list
| Type | Description |
|---|---|
| boolean |

getName(
)
:
voidReturns name of this target.
@return string The name of the target
- Access
- public

getProject(
)
:
voidReturns reference to current project
@return Project Reference to current porject object

getTasks(
)
:
arrayReturns an array of all tasks this target has as childrens.
The task objects are copied here. Don't use this method to modify task objects.
| Type | Description |
|---|---|
| array | Task[] |

main(
)
:
voidThe entry point for this class. Does some checking, then processes and performs the tasks for this target.

performTasks(
)
:
voidPerforms the tasks by calling the main method of this target that actually executes the tasks.
This method is for ZE2 and used for proper exception handling of task exceptions.

setDepends(
$depends
)
:
voidSets the target dependencies from xml
@param string $depends Comma separated list of targetnames that depend on this target
| Name | Type | Description |
|---|---|---|
| $depends |
| Exception | Description |
|---|---|
| \BuildException |

setDescription(
$description
)
:
voidSets a textual description of this target.
@param string The description text
| Name | Type | Description |
|---|---|---|
| $description |

setIf(
$property
)
:
voidSet the if-condition from the XML tag, if any. The property name given as parameter must be present so the if condition evaluates to true
@param string The property name that has to be present
| Name | Type | Description |
|---|---|---|
| $property |
- Access
- public

setName(
$name
)
:
voidSets the name of the target
@param string Name of this target
| Name | Type | Description |
|---|---|---|
| $name |

setProject(
$project
)
:
voidReferences the project to the current component.
@param Project The reference to the current project
| Name | Type | Description |
|---|---|---|
| $project |

setUnless(
$property
)
:
voidSet the unless-condition from the XML tag, if any. The property name given as parameter must be present so the unless condition evaluates to true
@param string The property name that has to be present
| Name | Type | Description |
|---|---|---|
| $property |
- Access
- public

testIfCondition(
)
:
voidTests if the property set in ifConfiditon exists.
@return boolean
true
if the property specified in
$this->ifCondition
exists;
false
otherwise

testUnlessCondition(
)
:
voidTests if the property set in unlessCondition exists.
@return boolean
true
if the property specified in
$this->unlessCondition
exists;
false
otherwise