|
|
File: c:/www/apache/doc2//xmlwriter/PhpdocXMLWriter.php
PHPDOC 2000/12/03 - PHPDoc
PhpdocXMLWriter
PhpdocObject | +-- PhpdocXMLWriter
Creates XML documents.
|
private class PhpdocXMLWriter extends PhpdocObject
Creates XML documents.
PHPDoc uses this helper class to generate xml documents. It'snot much what this class can do but it provides some simplefunctions to handle attributes and hides file handling tasks.
|
|
|
|
|
|
|
Private Field Summary |
string |
$xmlGenerated XML document. |
object PhpdocWarning |
$warnPHPDoc Warning object |
object PhpdocFilehandler |
$fileHandlerFilehandler used for IO operations |
|
Public Method Details |
PhpdocXMLWriter |
public void PhpdocXMLWriter( )
|
|
Creates a new PhpdocFileHandler
|
Returns |
void |
See Also |
$filehandler |
|
free |
public void free( )
|
|
Clears the internal xml data buffer so that a new document can be passed to the object.
|
Returns |
void |
|
addXML |
public void addXML( string $xml )
|
|
Adds xml to the generated xml.
|
Parameter |
|
|
Returns |
void |
|
export |
public void export( string $filename )
|
|
Saves the xml to the specified file.
|
Parameter |
|
string |
$filename |
|
|
of the target file |
|
Returns |
void |
|
startElement |
public void startElement( string $name, [ string $value, string $attribs, boolean $close ] )
|
|
Adds an open (or single) xml tag to the generated xml.
Use this function to add new elements/tags to the xml document.The tagname and all attributenames will be converted to lowercase.
|
Parameter |
|
|
|
string |
$value |
= >>""<< |
|
of the container: <name>value |
|
|
string |
$attribs |
= >>""<< |
|
of attributes: $attribs[n][type] = boolean|cdata, $attribs[n][value] = value |
|
|
boolean |
$close |
= >>false<< |
|
indication that you want an empty tag like <name/>. |
|
Returns |
void |
See Also |
endElement() |
|
endElement |
public void endElement( string $name )
|
|
Adds a closing xml tag to the generated xml document.
|
Parameter |
|
|
Returns |
void |
See Also |
startElement() |
|
addElement |
public void addElement( string $name, [ string $value, string $attribs ] )
|
|
Adds a complete xml container to the generated xml document.
|
Parameter |
|
|
|
|
|
|
Returns |
void |
See Also |
startElement(), endElement() |
|
|
Private Method Details |
xmlencode |
private string xmlencode( string $value )
|
|
Encodes XML values.
|
Parameter |
|
|
Returns |
string $value |
|
|
Private Field Details |
$xml |
private string $xml
>>"" <<
Generated XML document.
|
|
$warn |
private object PhpdocWarning $warn
>> <<
PHPDoc Warning object
|
|
$fileHandler |
private object PhpdocFilehandler $fileHandler
>> <<
Filehandler used for IO operations
|
See Also |
PhpdocXMLWriter() |
|
|
|
|
PHPDoc 1.0beta |