phing

# Class: IntrospectionHelper Source Location: /IntrospectionHelper.php
### Class Overview
Helper class that collects the methods that a task or nested element holds to set attributes, create nested elements or hold PCDATA elements. #### Author(s): Hans Lellelid <hans@xmpl.org> Andreas Aderhold <andi@binarycloud.com> #### Version: $Revision: 526 $ #### Copyright: © 2001,2002 THYRELL. All rights reserved | ### Methods __construct addText createElement getAttributes getElementName getHelper getNestedElements getPropertyName setAttribute storeElement supportsCharacters warn
### Class Details [line 43] Helper class that collects the methods that a task or nested element holds to set attributes, create nested elements or hold PCDATA elements. <strong>SMART-UP INLINE DOCS</strong> <strong>POLISH-UP THIS CLASS</strong> #### Tags:
author: | Hans Lellelid <hans@xmpl.org>
author: | Andreas Aderhold <andi@binarycloud.com>
version: | $Revision: 526 $
copyright: | © 2001,2002 THYRELL. All rights reserved
[ Top ] ### Class Methods ### static method getHelper [line 111]
`static void getHelper( string $class)`
Factory method for helper objects. #### Tags:
access: | public
#### Parameters:
string | $class | The class to create a Helper for
[ Top ] ### constructor __construct [line 128]
`IntrospectionHelper __construct( $class, string $bean)`
This function constructs a new introspection helper for a specific class. This method loads all methods for the specified class and categorizes them as setters, creators, slot listeners, etc. This way, the setAttribue() doesn't need to perform any introspection -- either the requested attribute setter/creator exists or it does not & a BuildException is thrown. #### Parameters:
string | $bean | The classname for this IH.
| $class |
[ Top ] ### method addText [line 364]
`void addText( Project $project, $element, $text)`
Adds PCDATA areas. #### Parameters:
Project | $project |
| $element |
| $text |
[ Top ] ### method createElement [line 384]
`object Returns createElement( Project $project, $element, $elementName)`
Creates a named nested element. Valid creators can be in the form createFoo() or addFoo(Bar). #### Tags:
return: | the nested element.
throws: | BuildException
#### Parameters:
Project | $project |
| $element |
| $elementName |
[ Top ] ### method getAttributes [line 472]
`void getAttributes( )`
Return all attribues supported by the introspected class. [ Top ] ### method getElementName [line 495]
`string getElementName( Project $project, object $element)`
Get the the name for an element. When possible the full classnam (phing.tasks.system.PropertyTask) will be returned. If not available (loaded in taskdefs or typedefs) then the XML element name will be returned. #### Tags:
return: | Fully qualified class name of element when possible.
#### Parameters:
Project | $project |
object | $element | The Task or type element.
[ Top ] ### method getNestedElements [line 481]
`void getNestedElements( )`
Return all nested elements supported by the introspected class. [ Top ] ### method getPropertyName [line 528]
`void getPropertyName( $methodName, $prefix)`
extract the name of a property from a method name - subtracting a given prefix. #### Parameters:
| $methodName |
| $prefix |
[ Top ] ### method setAttribute [line 270]
`void setAttribute( Project $project, $element, $attributeName, &$value)`
Sets the named attribute. #### Parameters:
Project | $project |
| $element |
| $attributeName |
| &$value |
[ Top ] ### method storeElement [line 444]
`void storeElement( $project, $element, $child, [ $elementName = null])`
Creates a named nested element. #### Tags:
throws: | BuildException
#### Parameters:
| $project |
| $element |
| $child |
| $elementName |
[ Top ] ### method supportsCharacters [line 467]
`void supportsCharacters( )`
Does the introspected class support PCDATA? [ Top ] ### method warn [line 536]
`void warn( $msg)`
Prints warning message to screen if -debug was used. #### Parameters:
| $msg |
[ Top ] Documentation generated on Mon, 19 Oct 2009 10:51:07 +0200 by phpDocumentor 1.4.3