|
|
File: c:/www/apache/doc2//xmlexporter/PhpdocXMLExporter.php
PHPDOC 2000/12/03 - PHPDoc
PhpdocXMLExporter
PhpdocObject | +-- PhpdocXMLExporter
Exporter used to export phpdoc internals data structures as xml documents.
|
private class PhpdocXMLExporter extends PhpdocObject
Exporter used to export phpdoc internals data structures as xml documents.
|
|
Direct known subclasses: PhpdocXMLDocumentExporter, PhpdocXMLIndexExporter, PhpdocXMLWarningExporter
|
|
|
|
|
|
Private Field Summary |
string |
$fileprefixFilename prefix for the generated xml document. |
string |
$pathTarget directory where the xml documents get saved. |
array |
$resultData to save as a xml document. |
object PhpdocXMLWriter |
$xmlwriterInstance of PhpdocXMLWriter used to generate the xml document. |
|
Public Method Details |
PhpdocXMLExporter |
public void PhpdocXMLExporter( )
|
|
Creates a PhpdocXMLWriter object.
Make sure that all derived classes call this constructor.
|
Returns |
void |
See Also |
$xmlwriter |
|
setPath |
public void setPath( string $path )
|
|
Sets the target path for the generated xml documents.
|
Parameter |
|
|
Returns |
void |
See Also |
$path |
|
export |
public void export( array $result, [ string $xmlfile ] )
|
|
Exports the given result array as xml document.
|
Parameter |
|
|
|
string |
$xmlfile |
= >>""<< |
|
of the target xml file |
|
Returns |
void |
See Also |
$result |
|
|
Private Method Details |
setResult |
private void setResult( array $result )
|
|
|
Parameter |
|
|
Returns |
void |
|
getAttributes |
private array getAttributes( array $data, array $allowed )
|
|
Kind of array_intersect for xml attributes.
This functions takes a data array and a list of allowed fields in the dataarray. All of the allowed fields that exists in the data array will becopied to returned array which looks like:$attribs[name] = array ( type => allowed[name], value => data[name] ).This structure is used by PhpdocXMLWriter->addElement().
|
Parameter |
|
|
|
array |
$allowed |
|
|
of allowed fields and their attribute type |
|
Returns |
array $attribs |
|
|
Private Field Details |
$fileprefix |
private string $fileprefix
>>"" <<
Filename prefix for the generated xml document.
This class variable must be overriden by all derived classes.PHPDoc uses the filename prefix to detect the content ofthe file.
|
|
$path |
private string $path
>>"" <<
Target directory where the xml documents get saved.
|
See Also |
setPath() |
|
$result |
private array $result
>>array() <<
Data to save as a xml document.
|
See Also |
setResult(), export() |
|
$xmlwriter |
private object PhpdocXMLWriter $xmlwriter
>> <<
Instance of PhpdocXMLWriter used to generate the xml document.
|
See Also |
PhpdocXMLExporter() |
|
|
|
|
PHPDoc 1.0beta |