Description
Converter
|
--XMLDocBookConverter
Located in File: /phpDocumentor/Converters/XML/DocBook/XMLDocBookConverter.inc
XML DocBook converter.
This Converter takes output from the Parser and converts it to DocBook output
Method Detail
Summary:
XMLDocBookConverter
XMLDocBookConverter
(
&$allp,
&$packp,
&$classes,
&$procpages,
$po,
$pp,
$qm,
$targetDir,
$templateDir,
$title)
mixed
getClassLink
(
string $expr,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true], [
$with_a =
true])
mixed
getDefineLink
(
string $expr,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true])
mixed
getFunctionLink
(
string $expr,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true])
mixed
getGlobalLink
(
string $expr,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true])
string
getId
(
mixed &$el)
void
&getLink
(
$expr, [
$package =
false], [
$packages =
false])
mixed
getMethodLink
(
string $expr,
string $class,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true])
mixed
getPageLink
(
string $expr,
string $package, [
string $path =
false], [
boolean $text =
false], [
boolean $local =
true])
mixed
getVarLink
(
string $expr,
string $class,
string $package, [
string $file =
false], [
boolean $text =
false], [
boolean $local =
true])
void
returnSee
(
abstractLink &$element, [
string $eltext =
false], [
boolean $local =
true], [
boolean $with_a =
true])
Constructor XMLDocBookConverter (line 167)
XMLDocBookConverter XMLDocBookConverter(
&$allp,
&$packp,
&$classes,
&$procpages,
$po,
$pp,
$qm,
$targetDir,
$templateDir,
$title)
sets $base_dir to $targetDir
Parameters
- &$allp:
- &$packp:
- &$classes:
- &$procpages:
- $po:
- $pp:
- $qm:
- $targetDir:
- $templateDir:
- $title:
Info
Method convertClass (line 811)
void convertClass(
parserClass
&$element)
Overrides : Converter::convertClass() Default Class Handler
Converts class for template output
Parameters
Info
Method convertDefine (line 1021)
void convertDefine(
parserDefine
&$element)
Overrides : Converter::convertDefine() Converts defines for template output
Converts defines for template output
Parameters
Info
Method ConvertErrorLog (line 625)
void ConvertErrorLog(
)
Overrides : Converter::ConvertErrorLog() Convert the phpDocumentor parsing/conversion error log
Create errors.html template file output
This method takes all parsing errors and warnings and spits them out ordered by file and line number.
Info
- global - ErrorTracker $phpDocumentor_errors: We'll be using it's output facility
Method convertFunction (line 952)
void convertFunction(
parserFunction
&$element)
Overrides : Converter::convertFunction() Converts function for template output
Converts function for template output
Parameters
Info
Method convertGlobal (line 1040)
void convertGlobal(
parserGlobal
&$element)
Overrides : Converter::convertGlobal() Converts global variables for template output
Converts global variables for template output
Parameters
Info
Method convertInclude (line 1003)
void convertInclude(
parserInclude
&$element)
Overrides : Converter::convertInclude() Converts includes for template output
Converts include elements for template output
Parameters
Info
Method convertMethod (line 873)
void convertMethod(
parserMethod
&$element)
Overrides : Converter::convertMethod() Converts method for template output
Converts method for template output
Parameters
Info
Method convertPackagePage (line 712)
void convertPackagePage(
parserPackagePage
&$element)
Converts package page and sets its package as used in $package_pages
Parameters
Info
Method convertPage (line 1062)
void convertPage(
parserData
&$element)
Overrides : Converter::convertPage() Default Page Handler
converts procedural pages for template output
Parameters
Info
Method convertTutorial (line 736)
void convertTutorial(
&$element)
Overrides : Converter::convertTutorial() Default Tutorial Handler
Parameters
Info
Method convertVar (line 774)
void convertVar(
parserVar
&$element)
Overrides : Converter::convertVar() Converts class variables for template output.
Converts class variables for template output.
Parameters
Info
Method endClass (line 217)
void endClass(
)
Overrides : Converter::endClass() Called by walk() while converting, when the last class element has been parsed.
Writes out the template file of $class_data and unsets the template to save memory
Info
Method endPage (line 249)
void endPage(
)
Overrides : Converter::endPage() Called by walk() while converting, when the last procedural page element has been parsed.
Writes out the template file of $page_data and unsets the template to save memory
Info
Method formatIndex (line 360)
void formatIndex(
)
Overrides : Converter::formatIndex() Called by walk() while converting.
HTMLdefaultConverter uses this function to format template index.html and packages.html
This function generates the package list from $all_packages, eliminating any packages that don't have any entries in their package index (no files at all, due to @ignore or other factors). Then it uses the default package name as the first package index to display. It sets the right pane to be either a blank file with instructions on making package-level docs, or the package-level docs for the default package.
Info
- global - string $phpDocumentor_DefaultPackageName: Used to set the starting package to display
Method formatLeftIndex (line 438)
void formatLeftIndex(
)
Overrides : Converter::formatLeftIndex() Called by walk() while converting.
Generate indexes for li_package.html and classtree output files
This function generates the li_package.html files from the template file left.html. It does this by iterating through each of the $page_elements, $class_elements and $function_elements arrays to retrieve the pre-sorted abstractLink descendants needed for index generation. Conversion of these links to text is done by returnSee(). The $local parameter is set to false to ensure that paths are correct.
Then it uses generateFormattedClassTrees() to create class trees from the template file classtrees.html. Output filename is classtrees_packagename.html. This function also unsets $elements and $pkg_elements to free up the considerable memory these two class vars use
Info
Method formatPkgIndex (line 327)
void formatPkgIndex(
)
Overrides : Converter::formatPkgIndex() Called by walk() while converting.
HTMLdefaultConverter chooses to format both package indexes and the complete index here
This function formats output for the elementindex.html and pkgelementindex.html template files. It then writes them to the target directory
Info
Method generateElementIndex (line 1260)
void generateElementIndex(
)
Generate alphabetical index of all elements
Info
Method generateFormattedClassTree (line 1122)
array generateFormattedClassTree(
parserClass
$class)
Overrides : Converter::generateFormattedClassTree() returns an array containing the class inheritance tree from the root object to the class.
returns an array containing the class inheritance tree from the root object to the class
Parameters
Info
Method generateFormattedClassTrees (line 1172)
void generateFormattedClassTrees(
string
$package)
returns a template-enabled array of class trees
Parameters
- string $package: package to generate a class tree for
Info
- see - $roots, HTMLConverter::getRootTree()
Method generatePkgElementIndex (line 1448)
void generatePkgElementIndex(
string
$package)
Generate alphabetical index of all elements by package and subpackage
Parameters
- string $package: name of a package
Info
Method generatePkgElementIndexes (line 1588)
void generatePkgElementIndexes(
)
Info
Method getCData (line 703)
void getCData(
$value)
Parameters
Info
Method getClassLink (line 1628)
mixed getClassLink(
string
$expr, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true], [
$with_a = true])
Overrides : Converter::getClassLink() return false or a classLink to $expr
Parameters
- string $expr: name of class
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
- $with_a:
Info
Method getDefineLink (line 1660)
mixed getDefineLink(
string
$expr, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getDefineLink() return false or a defineLink to $expr
Parameters
- string $expr: name of define
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method getFunctionLink (line 1644)
mixed getFunctionLink(
string
$expr, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getFunctionLink() return false or a functionLink to $expr
Parameters
- string $expr: name of function
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method getGlobalLink (line 1676)
mixed getGlobalLink(
string
$expr, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getGlobalLink() return false or a globalLink to $expr
Parameters
- string $expr: name of global variable
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method getId (line 574)
string getId(
mixed
&$el)
Overrides : Converter::getId() take abstractLink descendant and text $eltext and return a
Get the id value needed to allow linking
Parameters
- mixed &$el: descendant of parserElement or parserData/parserPage
Info
Method getLink (line 175)
void &getLink(
$expr, [
$package = false], [
$packages = false])
Overrides : Converter::getLink() The meat of the @see tag and inline {@link} tag
do that stuff in $template_options
Parameters
- $expr:
- $package:
- $packages:
Info
Method getMethodLink (line 1709)
mixed getMethodLink(
string
$expr, string
$class, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getMethodLink() return false or a methodLink to $expr in $class
Parameters
- string $expr: name of method
- string $class: class containing method
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method getPageLink (line 1692)
mixed getPageLink(
string
$expr, string
$package, [string
$path = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getPageLink() return false or a pageLink to $expr
Parameters
- string $expr: name of procedural page
- string $package: package name
- string $path: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method getPageName (line 1109)
void getPageName(
&$element)
Parameters
Info
Method getRootTree (line 1191)
string getRootTree(
array
$tree,
$package)
return formatted class tree for the Class Trees page
Parameters
Info
Method getTutorialId (line 696)
void getTutorialId(
$package,
$subpackage,
$tutorial,
$id)
Overrides : Converter::getTutorialId() Return a converter-specific id to distinguish tutorials and their sections
Parameters
- $package:
- $subpackage:
- $tutorial:
- $id:
Info
Method getVarLink (line 1726)
mixed getVarLink(
string
$expr, string
$class, string
$package, [string
$file = false], [boolean
$text = false], [boolean
$local = true])
Overrides : Converter::getVarLink() return false or a varLink to $expr in $class
Parameters
- string $expr: name of var
- string $class: class containing var
- string $package: package name
- string $file: full path to look in (used in index generation)
- boolean $text: deprecated
- boolean $local: return just the URL, or enclose it in an html a tag
Info
Method makeLeft (line 282)
void makeLeft(
)
Info
Method Output (line 1783)
void Output(
)
Overrides : Converter::Output() do all necessary output
This function is not used by HTMLdefaultConverter, but is required by Converter
Info
Method postProcess (line 686)
void postProcess(
$text)
Overrides : Converter::postProcess() This version does nothing
Parameters
Info
Method prepareDocBlock (line 691)
void prepareDocBlock(
&$element, [
$nopackage = true])
Overrides : Converter::prepareDocBlock() convert the element's DocBlock for output
Parameters
Info
Method rcNatCmp (line 1740)
int rcNatCmp(
mixed
$a, mixed
$b)
does a nat case sort on the specified second level value of the array
Parameters
Info
Method rcNatCmp1 (line 1756)
int rcNatCmp1(
mixed
$a, mixed
$b)
does a nat case sort on the specified second level value of the array.
this one puts constructors first
Parameters
Info
Method returnLink (line 277)
string returnLink(
string
$link, string
$text)
Overrides : Converter::returnLink() take URL $link and text $text and return a link in the format needed for the Converter
Parameters
- string $link:
- string $text:
Info
- return - <ulink url="'.$link.'">'.$text.'</ulink>
Method returnSee (line 476)
void returnSee(
abstractLink
&$element, [string
$eltext = false], [boolean
$local = true], [boolean
$with_a = true])
Overrides : Converter::returnSee() take abstractLink descendant and text $eltext and return a link
This function takes an abstractLink descendant and returns an html link
Parameters
- abstractLink &$element: a descendant of abstractlink should be passed, and never text
- string $eltext: text to display in the link
- boolean $local: this parameter is not used, and is deprecated
- boolean $with_a: determines whether the returned text is enclosed in an <a> tag
Info
Method setTargetDir (line 1388)
void setTargetDir(
$dir)
Overrides : Converter::setTargetDir() Sets the output directory for generated documentation
calls the converter setTargetDir, and then copies any template images and the stylesheet if they haven't been copied
Parameters
Info
Method setTemplateDir (line 1378)
void setTemplateDir(
$dir)
Overrides : Converter::setTemplateDir() sets the template directory based on the $outputformat and $name
Parameters
Info
Method SmartyInit (line 205)
void &SmartyInit(
&$templ)
Parameters
Info
Method writeNewPPage (line 406)
void writeNewPPage(
$key)
Parameters
Info