phing-parser
[ class tree: phing-parser ] [ index: phing-parser ] [ all elements ]

Class: TaskHandler

Source Location: /parser/TaskHandler.php

Class Overview

AbstractHandler
   |
   --TaskHandler

The task handler class.


Author(s):

Version:

  • $Revision: 552 $

Copyright:

  • � 2001,2002 THYRELL. All rights reserved

Methods


Inherited Variables

Inherited Methods

Class: AbstractHandler

AbstractHandler::__construct()
Constructs a SAX handler parser.
AbstractHandler::characters()
Invoked by occurance of #PCDATA.
AbstractHandler::endElement()
Gets invoked when a XML element ends.
AbstractHandler::finished()
Gets invoked when element closes method.
AbstractHandler::startElement()
Gets invoked when a XML open tag occurs

Class Details

[line 36]
The task handler class.

This class handles the occurance of a <task> tag and it's possible nested tags (datatypes and tasks) that may be unknown off bat and are initialized on the fly.




Tags:

author:  Andreas Aderhold <andi@binarycloud.com>
version:  $Revision: 552 $
copyright:  � 2001,2002 THYRELL. All rights reserved


[ Top ]


Class Methods


constructor __construct [line 90]

TaskHandler __construct( AbstractSAXParser $parser, object $parentHandler, ProjectConfigurator $configurator, [TaskContainer $container = null], [RuntimeConfigurable $parentWrapper = null], [Target $target = null])

Constructs a new TaskHandler and sets up everything.



Overrides AbstractHandler::__construct() (Constructs a SAX handler parser.)

Parameters:

object   $parentHandler   The parent handler that invoked this handler
ProjectConfigurator   $configurator  
TaskContainer   $container   The container object this task is contained in (null for top-level tasks).
RuntimeConfigurable   $parentWrapper   Wrapper for the parent element, if any.
Target   $target   The target object this task is contained in (null for top-level tasks).
AbstractSAXParser   $parser   The ExpatParser object

[ Top ]

method characters [line 201]

void characters( string $data)

Handles character data.



Overrides AbstractHandler::characters() (Invoked by occurance of #PCDATA.)

Parameters:

string   $data   The CDATA that comes in

[ Top ]

method finished [line 185]

void finished( )

Executes the task at once if it's directly beneath the <project> tag.



Tags:

access:  protected


Overrides AbstractHandler::finished() (Gets invoked when element closes method.)

[ Top ]

method init [line 128]

void init( string $tag, array $attrs)

Executes initialization actions required to setup the data structures related to the tag.

This includes:

  • creation of the task object
  • calling the setters for attributes
  • adding the task to the container object
  • adding a reference to the task (if id attribute is given)
  • executing the task if the container is the &lt;project&gt; element




Tags:

throws:  ExpatParseException if attributes are incomplete or invalid


Parameters:

string   $tag   The tag that comes in
array   $attrs   Attributes the tag carries

[ Top ]

method startElement [line 222]

void startElement( string $name, array $attrs)

Checks for nested tags within the current one. Creates and calls handlers respectively.



Overrides AbstractHandler::startElement() (Gets invoked when a XML open tag occurs)

Parameters:

string   $name   The tag that comes in
array   $attrs   Attributes the tag carries

[ Top ]


Documentation generated on Mon, 19 Oct 2009 10:52:14 +0200 by phpDocumentor 1.4.3