Class XMLPackagePageParser

Description

Used to parse XML DocBook-based tutorials

Located in /phpDocumentor/XMLpackagePageParser.inc (line 98)

Publisher
   |
   --Parser
      |
      --XMLPackagePageParser
Variable Summary
array $context
array $pars
mixed $refsect1id
mixed $refsect2id
mixed $refsect3id
Method Summary
static mixed getParserEventName (mixed $value)
XMLPackagePageParser XMLPackagePageParser ()
bool parse (string $parse_data, array $tutorial)
void setupStates ()
Variables
array $context (line 125)
  • var: the tag stack
array $eventHandlers = array(
PHPDOCUMENTOR_PDP_EVENT_TAG => 'handleTag',
PHPDOCUMENTOR_PDP_EVENT_ATTRIBUTES => 'handleAttributes',
PHPDOCUMENTOR_PDP_EVENT_CDATA => 'handleCData',
PARSER_EVENT_NOEVENTS => 'defaultHandler',
PARSER_EVENT_COMMENTBLOCK => 'ignoreHandler',
PARSER_EVENT_OUTPHP => 'ignoreHandler',
PARSER_EVENT_QUOTE => 'handleQuote',
PHPDOCUMENTOR_PDP_EVENT_ENTITY => 'handleEntity',
)
(line 103)
array $pars = array() (line 117)
mixed $refsect1id = false (line 119)
mixed $refsect2id = false (line 120)
mixed $refsect3id = false (line 121)

Inherited Variables

Inherited from Publisher

Publisher::$subscriber
Methods
static getParserEventName (line 615)

debugging function

  1. function getParserEventName ($value)
  2.     {    
  3.         $lookup array(
  4.             PARSER_EVENT_NOEVENTS
  5.                 => "PARSER_EVENT_NOEVENTS",
  6.             PHPDOCUMENTOR_PDP_EVENT_TAG
  7.                 => "PHPDOCUMENTOR_PDP_EVENT_TAG",
  8.             PHPDOCUMENTOR_PDP_EVENT_ATTRIBUTES
  9.                 => "PHPDOCUMENTOR_PDP_EVENT_ATTRIBUTES",
  10.             PHPDOCUMENTOR_PDP_EVENT_CDATA
  11.                 => "PHPDOCUMENTOR_PDP_EVENT_CDATA",
  12.             PHPDOCUMENTOR_PDP_EVENT_LIST
  13.                 => "PHPDOCUMENTOR_PDP_EVENT_LIST",
  14.             PARSER_EVENT_QUOTE
  15.                 => "PARSER_EVENT_QUOTE",
  16.             PHPDOCUMENTOR_PDP_EVENT_ENTITY
  17.                 => "PHPDOCUMENTOR_PDP_EVENT_ENTITY",
  18.             PHPDOCUMENTOR_PDP_EVENT_COMMENT
  19.                 => "PHPDOCUMENTOR_PDP_EVENT_COMMENT",
  20.             PHPDOCUMENTOR_PDP_EVENT_PI
  21.                 => "PHPDOCUMENTOR_PDP_EVENT_PI",
  22.         );
  23.         if (isset($lookup[$value])) {
  24.             return $lookup[$value];
  25.         else {
  26.             return $value;
  27.         }
  28.     }

  • return: the looked up value if found, else the original value
static mixed getParserEventName (mixed $value)
  • mixed $value: a value

Redefinition of:
Parser::getParserEventName()
Debugging function, takes an event number and attempts to return its name
Constructor XMLPackagePageParser (line 138)

Set up the wordparser

  1.     {
  2.         $this->wp new ObjectWordParser(true);
  3.     }

XMLPackagePageParser XMLPackagePageParser ()
parse (line 155)

Parse a new file

  • staticvar: integer $endrecur: used for recursion limiting if a handler for an event is not found
  • uses: parserTutorial - using Publisher::PublishEvent(), a new tutorial is created from the file parsed, and passed to the Intermediate Parser
bool parse (string $parse_data, array $tutorial)

Redefinition of:
Parser::parse()
Parse a new file
setupStates (line 524)

setup the parser tokens, and the pushEvent/popEvent arrays

void setupStates ()

Redefinition of:
Parser::setupStates()
setup the parser tokens, and the pushEvent/popEvent arrays

Inherited Methods

Inherited From Parser

Parser::Parser()
Parser::categoryTagHandler()
Parser::checkEventPop()
Parser::checkEventPush()
Parser::configWordParser()
Parser::defaultTagHandler()
Parser::endTag()
Parser::exampleTagHandler()
Parser::getParserEventName()
Parser::globalTagHandler()
Parser::invalidTagHandler()
Parser::packageTagHandler()
Parser::paramTagHandler()
Parser::parse()
Parser::propertyTagHandler()
Parser::returnTagHandler()
Parser::setupStates()
Parser::staticvarTagHandler()
Parser::usesTagHandler()
Parser::varTagHandler()

Inherited From Publisher

Publisher::publishEvent()
Publisher::subscribe()

Documentation generated on Mon, 05 Dec 2011 21:12:53 -0600 by phpDocumentor 1.4.4