Markup

クラス: Peach_Markup_DebugContext

定義: /Peach/Markup/DebugContext.php

Peach_Markup_Context
   |
   +-Peach_Markup_DebugContext

デバッグのために使用される Context です.

この Context は, handle メソッドを実行した時に自動で echo を行います. 出力内容は, ノードツリーの構造を可視化した文字列となります.

メソッド

継承されたメソッド

クラス: Peach_Markup_Context

Peach_Markup_Context::getResult()
処理結果を取得します. まだ handle() が実行されていない場合は NULL を返します.
Peach_Markup_Context::handle()
指定されたオブジェクトを処理します.
Peach_Markup_Context::handleCode()
整形済テキストを処理します.
Peach_Markup_Context::handleComment()
コメントノードを処理します.
Peach_Markup_Context::handleContainerElement()
コンテナ要素を処理します.
Peach_Markup_Context::handleEmptyElement()
空要素タグを処理します.
Peach_Markup_Context::handleNodeList()
NodeList を処理します.
Peach_Markup_Context::handleNone()
None を処理します.
Peach_Markup_Context::handleText()
テキストノードを処理します.

メソッド 詳細

constructor __construct

line 54

Peach_Markup_DebugContext __construct([bool $echoMode = true])

新しい DebugContext を構築します.

Tags

  • access : public

引数

bool   $echoMode   自動で出力を行うかどうかの設定 (デフォルトで true)

getResult

line 116

string getResult()

デバッグ用の出力データを返します.

Tags

  • access : public

オーバーライド: Peach_Markup_Context::getResult() (処理結果を取得します. まだ handle() が実行されていない場合は NULL を返します.)

handleCode

line 210

void handleCode(Peach_Markup_Code $node)

Code ノードのデバッグ文字列を出力します.

出力内容は文字列 "Code" です.

Tags

  • access : public

引数

Peach_Markup_Code   $node  

オーバーライド: Peach_Markup_Context::handleCode() (整形済テキストを処理します.)

handleComment

line 133

void handleComment(Peach_Markup_Comment $node)

Comment ノードのデバッグ文字列を出力します.

出力内容は以下の通りです.

  1.  Comment {
  2.      # 子ノードの出力内容
  3.  }

Tags

  • access : public

引数

Peach_Markup_Comment   $node  

オーバーライド: Peach_Markup_Context::handleComment() (コメントノードを処理します.)

handleContainerElement

line 152

void handleContainerElement(Peach_Markup_ContainerElement $node)

ContainerElement ノードのデバッグ文字列を出力します.

出力内容は以下の通りです.

  1.  ContainerElement(tagName{
  2.      # 子ノードの出力内容
  3.  }

Tags

  • access : public

引数

Peach_Markup_ContainerElement   $node  

オーバーライド: Peach_Markup_Context::handleContainerElement() (コンテナ要素を処理します.)

handleEmptyElement

line 170

void handleEmptyElement(Peach_Markup_EmptyElement $node)

EmptyElement ノードのデバッグ文字列を出力します.

出力内容は以下の通りです.

  1.  EmptyElement(tagName)

Tags

  • access : public

引数

Peach_Markup_EmptyElement   $node  

オーバーライド: Peach_Markup_Context::handleEmptyElement() (空要素タグを処理します.)

handleNodeList

line 188

void handleNodeList(Peach_Markup_NodeList $node)

NodeList のデバッグ文字列を出力します.

出力内容は以下の通りです.

  1.  NodeList {
  2.      # 子ノードの出力内容
  3.  }

Tags

  • access : public

引数

Peach_Markup_NodeList   $node  

オーバーライド: Peach_Markup_Context::handleNodeList() (NodeList を処理します.)

handleNone

line 220

void handleNone(Peach_Markup_None $none)

None のデバッグ文字列を出力します.

出力内容は文字列 "None" です.

Tags

  • access : public

引数

Peach_Markup_None   $none  

オーバーライド: Peach_Markup_Context::handleNone() (None を処理します.)

handleText

line 200

void handleText(Peach_Markup_Text $node)

Text ノードのデバッグ文字列を出力します.

出力内容は文字列 "Text" です.

Tags

  • access : public

引数

Peach_Markup_Text   $node  

オーバーライド: Peach_Markup_Context::handleText() (テキストノードを処理します.)