# classes/phing/types/TokenSource.php

## \TokenSource
jump to top

A parameter is composed of a name, type and value.

Example of usage:

<replacetokens> </replacetokens>

or:

<param type="tokensource>

Extends from
  \DataType
author
  Yannick Lecaillez
package
  phing.types
version
  $Revision: 526 $

### Properties

`string $classname= 'null'`

String to hold the path to the TokenReader

Default value `null` Details

Type
  string

`array $parameters= 'array'`

Array holding parameters for the wrapped TokenReader.

Default value `array` Details

Type
  array

`\TokenReader $reader= ''`

Reference to the TokenReader used by this TokenSource

Details

Type
  \TokenReader

`$tokens= 'array'`

Array with key/value pairs of tokens

Default value `array` Details

Type

### Methods

`configureTokenReader( \TokenReader $reader ) :`
Configures a TokenReader with the parameters passed to the TokenSource.
Parameters

Name | Type | Description
--- | --- | ---
$reader | \TokenReader |

`createParam( ) : \Parameter`
Create nested tag.

Uses standard name/value Parameter class.

Returns

Type | Description
--- | ---
\Parameter |

`getClassname( ) : string`
Returns the qualified classname (dot-path) to use for handling token replacement.
Returns

Type | Description
--- | ---
string |

`getTokens( ) :`
This function uses the wrapper to read the tokens and then returns them.
Details

access
  public

`load( ) :`
This method is called to load the sources from the reader into the buffer of the source.
`setClassname( string $c ) :`
Set the classname (dot-path) to use for handling token replacement.
Parameters

Name | Type | Description
--- | --- | ---
$c | string |

Documentation was generated by DocBlox 0.13.1.