Class PDFdefaultConverter

Description

PDF output converter.

This Converter takes output from the Parser and converts it to PDF-ready output for use with Cezpdf. This is now beta code

  • author: Greg Beaver <[email protected]>
  • version: $Id: PDFdefaultConverter.inc 317560 2011-09-30 22:54:26Z ashnazg $
  • todo: Implement links to conflicts/inheritance
  • since: 1.1

Located in /phpDocumentor/Converters/PDF/default/PDFdefaultConverter.inc (line 55)

Converter
   |
   --PDFdefaultConverter
Variable Summary
Method Summary
 PDFdefaultConverter PDFdefaultConverter ( &$allp,  &$packp,  &$classes,  &$procpages,  $po,  $pp,  $qm,  $targetDir,  $templateDir,  $title)
 void convertClass ( &$element)
 void convertConst ( &$element)
 void convertDefine ( &$element)
 void convertDocBlock ( &$element)
 void convertFunction ( &$element)
 void convertGlobal ( &$element)
 void convertInclude ( &$element)
 void convertMethod ( &$element)
 void convertPackagepage ( &$element)
 void convertPage ( &$element)
 void convertParams ( &$element)
 void convertTutorial ( &$element)
 void convertVar ( &$element)
 void Convert_RIC (README|INSTALL|CHANGELOG $name, string $contents)
 void generateFormattedClassTrees (string $package)
 void getCData ( $value)
 mixed getClassLink (string $expr, string $package, [string $file = false], [ $text = false])
 mixed getConstLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)
 mixed getDefineLink (string $expr, string $package, [string $file = false], [boolean $text = false])
 void getExampleLink ( $path,  $title)
 void getFileSourceName ( $path, [ $anchor = ''])
 mixed getFunctionLink (string $expr, string $package, [string $file = false], [boolean $text = false])
 mixed getGlobalLink (string $expr, string $package, [string $file = false], [boolean $text = false])
 void getGlobalValue ( $value)
 mixed getMethodLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false])
 mixed getPageLink (string $expr, string $package, [string $path = false], [boolean $text = false])
 void getPageName ( &$element)
 string getRootTree (array $tree,  $package)
 string getSourceAnchor (string $sourcefile, string $anchor, [string $text = ''], [boolean $link = false])
 void getSourceLink ( $path)
 1 getState ()
 void getTutorialId ( $package,  $subpackage,  $tutorial,  $id)
 mixed getVarLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)
 void mystrnatcasecmp ( $a,  $b)
 void Output ([ $title = 'Generated Documentation'])
 void postProcess ( $text)
 string returnLink (string $link, string $text)
 void returnSee (abstractLink &$element, [string $eltext = false])
 void setTemplateDir ( $dir)
 string TranslateTag (string $name, string $attr, string $cdata, string $unconvertedcdata)
 void unmangle ( $notused,  $source)
 void writeExample ( $title,  $path,  $source)
 void writeSource ( $path,  $value)
Variables
mixed $classpackage_pagenums = array() (line 65)
mixed $curclasspackage = false (line 71)
mixed $curpagepackage = false (line 70)
mixed $leftindex = array('classes' => false, 'pages' => false, 'functions' => false, 'defines' => false, 'globals' => false) (line 63)

Redefinition of:
Converter::$leftindex
Controls which of the one-element-only indexes are generated.
string $name = 'default' (line 69)
  • var: always default
string $outputformat = 'PDF' (line 67)
  • var: always PDF

Redefinition of:
Converter::$outputformat
output format of this converter
mixed $pagepackage_pagenums = array() (line 64)
Cezpdf $pdf = false (line 76)
mixed $ric_set = array() (line 77)
mixed $smarty_dir (line 72)

Redefinition of:
Converter::$smarty_dir
Directory that the smarty templates are in
boolean $sort_absolutely_everything = true (line 62)

default PDF Converter wants elements sorted by type as well as alphabetically


Redefinition of:
Converter::$sort_absolutely_everything
This is used if the content must be passed in the order it should be read, i.e. by package, procedural then classes
array $_sourcecode (line 84)

Source files for appendix C are stored here

Format: array(array(package => packagename, code => array(highlightedsource code 1, ...)))

Inherited Variables

Inherited from Converter

Converter::$all_packages
Converter::$class
Converter::$classes
Converter::$class_contents
Converter::$class_data
Converter::$class_elements
Converter::$curfile
Converter::$curpage
Converter::$define_elements
Converter::$elements
Converter::$function_elements
Converter::$global_elements
Converter::$highlightingSource
Converter::$package
Converter::$packagecategories
Converter::$package_elements
Converter::$package_output
Converter::$package_parents
Converter::$page
Converter::$page_contents
Converter::$page_data
Converter::$page_elements
Converter::$parseprivate
Converter::$path
Converter::$pkg_elements
Converter::$processSpecialRoots
Converter::$quietmode
Converter::$sort_page_contents_by_type
Converter::$sourcePaths
Converter::$subpackage
Converter::$targetDir
Converter::$templateDir
Converter::$templateName
Converter::$template_options
Converter::$title
Converter::$todoList
Methods
Constructor PDFdefaultConverter (line 88)
PDFdefaultConverter PDFdefaultConverter ( &$allp,  &$packp,  &$classes,  &$procpages,  $po,  $pp,  $qm,  $targetDir,  $templateDir,  $title)
  • &$allp
  • &$packp
  • &$classes
  • &$procpages
  • $po
  • $pp
  • $qm
  • $targetDir
  • $templateDir
  • $title
convertClass (line 461)
void convertClass ( &$element)
  • &$element

Redefinition of:
Converter::convertClass()
Default Class Handler
convertConst (line 439)
void convertConst ( &$element)
  • &$element

Redefinition of:
Converter::convertConst()
Converts class constants for template output.
convertDefine (line 541)
void convertDefine ( &$element)
  • &$element

Redefinition of:
Converter::convertDefine()
Converts defines for template output
convertDocBlock (line 249)
void convertDocBlock ( &$element)
  • &$element
convertFunction (line 508)
void convertFunction ( &$element)
  • &$element

Redefinition of:
Converter::convertFunction()
Converts function for template output
convertGlobal (line 349)
void convertGlobal ( &$element)
  • &$element

Redefinition of:
Converter::convertGlobal()
Converts global variables for template output
convertInclude (line 494)
void convertInclude ( &$element)
  • &$element

Redefinition of:
Converter::convertInclude()
Converts includes for template output
convertMethod (line 376)
void convertMethod ( &$element)
  • &$element

Redefinition of:
Converter::convertMethod()
Converts method for template output
convertPackagepage (line 638)
void convertPackagepage ( &$element)
  • &$element
convertPage (line 562)
void convertPage ( &$element)
  • &$element

Redefinition of:
Converter::convertPage()
Default Page Handler
convertParams (line 331)
void convertParams ( &$element)
  • &$element
convertTutorial (line 645)
void convertTutorial ( &$element)
  • &$element

Redefinition of:
Converter::convertTutorial()
Default Tutorial Handler
convertVar (line 416)
void convertVar ( &$element)
  • &$element

Redefinition of:
Converter::convertVar()
Converts class variables for template output.
Convert_RIC (line 244)

Convert README/INSTALL/CHANGELOG file contents to output format

void Convert_RIC (README|INSTALL|CHANGELOG $name, string $contents)
  • README|INSTALL|CHANGELOG $name
  • string $contents: contents of the file

Redefinition of:
Converter::Convert_RIC()
Convert README/INSTALL/CHANGELOG file contents to output format
generateFormattedClassTrees (line 665)

returns a template-enabled array of class trees

void generateFormattedClassTrees (string $package)
  • string $package: package to generate a class tree for
getCData (line 630)
void getCData ( $value)
  • $value
getClassLink (line 844)
mixed getClassLink (string $expr, string $package, [string $file = false], [ $text = false])
  • string $expr: name of class
  • string $package: package name
  • string $file: full path to look in (used in index generation)
  • $text

Redefinition of:
Converter::getClassLink()
return false or a classLink to $expr
getConstLink (line 954)
mixed getConstLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)
  • boolean 5: return just the URL, or enclose it in an html a tag
  • string $expr: name of class constant
  • string $class: class containing class constant
  • string $package: package name
  • string $file: full path to look in (used in index generation)
  • boolean $text: deprecated

Redefinition of:
Converter::getConstLink()
return false or a constLink to $expr in $class
getDefineLink (line 874)
mixed getDefineLink (string $expr, string $package, [string $file = false], [boolean $text = false])
  • string $expr: name of define
  • string $package: package name
  • string $file: full path to look in (used in index generation)
  • boolean $text: deprecated

Redefinition of:
Converter::getDefineLink()
return false or a defineLink to $expr
getExampleLink (line 140)
void getExampleLink ( $path,  $title)
  • $path
  • $title
getFileSourceName (line 152)
void getFileSourceName ( $path, [ $anchor = ''])
  • $path
  • $anchor

Redefinition of:
Converter::getFileSourceName()
Translate the path info into a unique file name for the highlighted source code.
getFunctionLink (line 859)
mixed getFunctionLink (string $expr, string $package, [string $file = false], [boolean $text = false])
  • string $expr: name of function
  • string $package: package name
  • string $file: full path to look in (used in index generation)
  • boolean $text: deprecated

Redefinition of:
Converter::getFunctionLink()
return false or a functionLink to $expr
getGlobalLink (line 889)
mixed getGlobalLink (string $expr, string $package, [string $file = false], [boolean $text = false])
  • string $expr: name of global variable
  • string $package: package name
  • string $file: full path to look in (used in index generation)
  • boolean $text: deprecated

Redefinition of:
Converter::getGlobalLink()
return false or a globalLink to $expr
getGlobalValue (line 371)
void getGlobalValue ( $value)
  • $value

Redefinition of:
Converter::getGlobalValue()
Parse a global variable's default value for class initialization.
getMethodLink (line 920)
mixed getMethodLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false])
  • 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

Redefinition of:
Converter::getMethodLink()
return false or a methodLink to $expr in $class
getPageLink (line 904)
mixed getPageLink (string $expr, string $package, [string $path = false], [boolean $text = false])
  • string $expr: name of procedural page
  • string $package: package name
  • string $path: full path to look in (used in index generation)
  • boolean $text: deprecated

Redefinition of:
Converter::getPageLink()
return false or a pageLink to $expr
getPageName (line 619)
void getPageName ( &$element)
  • &$element
getRootTree (line 684)

return formatted class tree for the Class Trees page

string getRootTree (array $tree,  $package)
getSourceAnchor (line 167)

Retrieve a Converter-specific anchor to a segment of a source code file parsed via a @filesource tag.

  • return: link to an anchor, or the anchor
string getSourceAnchor (string $sourcefile, string $anchor, [string $text = ''], [boolean $link = false])
  • string $sourcefile: full path to source file
  • string $anchor: name of anchor
  • string $text: link text, if this is a link
  • boolean $link: returns either a link or a destination based on this parameter
getSourceLink (line 146)
void getSourceLink ( $path)
  • $path

Redefinition of:
Converter::getSourceLink()
getState (line 968)
  • return: always the same
1 getState ()

Redefinition of:
Converter::getState()
Return parserStringWithInlineTags::Convert() cache state
getTutorialId (line 625)
void getTutorialId ( $package,  $subpackage,  $tutorial,  $id)
  • $package
  • $subpackage
  • $tutorial
  • $id

Redefinition of:
Converter::getTutorialId()
Return a converter-specific id to distinguish tutorials and their sections
getVarLink (line 937)
mixed getVarLink (string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)
  • boolean 5: return just the URL, or enclose it in an html a tag
  • 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

Redefinition of:
Converter::getVarLink()
return false or a varLink to $expr in $class
mystrnatcasecmp (line 831)
void mystrnatcasecmp ( $a,  $b)
  • $a
  • $b
Output (line 752)

calls Cezpdf::ezOutput() and writes documentation.pdf to targetDir

void Output ([ $title = 'Generated Documentation'])
  • $title

Redefinition of:
Converter::Output()
do all necessary output
postProcess (line 121)
void postProcess ( $text)
  • $text

Redefinition of:
Converter::postProcess()
This version does nothing
returnLink (line 234)
  • return: <c:alink:$link>$text</c:alink>
string returnLink (string $link, string $text)
  • string $link
  • string $text

Redefinition of:
Converter::returnLink()
take URL $link and text $text and return a link in the format needed for the Converter
returnSee (line 184)

Returns a bookmark using Cezpdf 009

void returnSee (abstractLink &$element, [string $eltext = false])
  • abstractLink &$element: a descendant of abstractlink should be passed, and never text
  • string $eltext: text to display in the link

Redefinition of:
Converter::returnSee()
take abstractLink descendant and text $eltext and return a link
setTemplateDir (line 961)
void setTemplateDir ( $dir)
  • $dir

Redefinition of:
Converter::setTemplateDir()
sets the template directory based on the $outputformat and $name
TranslateTag (line 602)

Used to translate an XML DocBook tag from a tutorial by reading the options.ini file for the template.

string TranslateTag (string $name, string $attr, string $cdata, string $unconvertedcdata)
  • string $name: tag name
  • string $attr: any attributes Format: array(name => value)
  • string $cdata: the tag contents, if any
  • string $unconvertedcdata: the tag contents, if any, unpost-processed

Redefinition of:
Converter::TranslateTag()
Used to translate an XML DocBook tag from a tutorial by reading the options.ini file for the template.
unmangle (line 976)
void unmangle ( $notused,  $source)
  • $notused
  • $source

Redefinition of:
Converter::unmangle()
Called by parserSourceInlineTag::stringConvert() to allow converters to format the source code the way they'd like.
writeExample (line 126)
void writeExample ( $title,  $path,  $source)
  • $title
  • $path
  • $source

Redefinition of:
Converter::writeExample()
Write out the formatted source code for an example php file
writeSource (line 106)
void writeSource ( $path,  $value)
  • $path
  • $value

Redefinition of:
Converter::writeSource()
Write out the formatted source code for a php file

Inherited Methods

Inherited From Converter

 Converter::Converter()
 Converter::AttrToString()
 Converter::Bolden()
 Converter::Br()
 Converter::checkState()
 Converter::cleanup()
 Converter::Convert()
 Converter::convertClass()
 Converter::convertConst()
 Converter::convertDefine()
 Converter::ConvertErrorLog()
 Converter::convertFunction()
 Converter::convertGlobal()
 Converter::convertInclude()
 Converter::convertMethod()
 Converter::convertPage()
 Converter::ConvertTitle()
 Converter::ConvertTodoList()
 Converter::convertTutorial()
 Converter::convertVar()
 Converter::Convert_RIC()
 Converter::copyFile()
 Converter::createParentDir()
 Converter::EncloseList()
 Converter::EncloseParagraph()
 Converter::endClass()
 Converter::endPage()
 Converter::exampleProgramExample()
 Converter::flushHighlightCache()
 Converter::formatIndex()
 Converter::formatLeftIndex()
 Converter::formatPkgIndex()
 Converter::formatTutorialTOC()
 Converter::generateChildClassList()
 Converter::generateFormattedClassTree()
 Converter::getClassesOnPage()
 Converter::getClassLink()
 Converter::getConstLink()
 Converter::getConverterDir()
 Converter::getCurrentPageLink()
 Converter::getCurrentPageURL()
 Converter::getDefineLink()
 Converter::getFileSourceName()
 Converter::getFileSourcePath()
 Converter::getFormattedConflicts()
 Converter::getFormattedDescMethods()
 Converter::getFormattedDescVars()
 Converter::getFormattedImplements()
 Converter::getFormattedInheritedConsts()
 Converter::getFormattedInheritedMethods()
 Converter::getFormattedInheritedVars()
 Converter::getFormattedMethodImplements()
 Converter::getFormattedOverrides()
 Converter::getFunctionLink()
 Converter::getGlobalLink()
 Converter::getGlobalValue()
 Converter::getHighlightState()
 Converter::getId()
 Converter::getIncludeValue()
 Converter::getLink()
 Converter::getMethodLink()
 Converter::getPageLink()
 Converter::getSortedClassTreeFromClass()
 Converter::getSourceLink()
 Converter::getState()
 Converter::getTutorialId()
 Converter::getTutorialLink()
 Converter::getTutorialTree()
 Converter::getVarLink()
 Converter::hasSourceCode()
 Converter::hasTutorial()
 Converter::highlightDocBlockSource()
 Converter::highlightSource()
 Converter::highlightTutorialSource()
 Converter::Italicize()
 Converter::Kbdize()
 Converter::ListItem()
 Converter::newSmarty()
 Converter::Output()
 Converter::postProcess()
 Converter::prepareDocBlock()
 Converter::PreserveWhiteSpace()
 Converter::ProgramExample()
 Converter::returnLink()
 Converter::returnSee()
 Converter::Sampize()
 Converter::setSourcePaths()
 Converter::setTargetDir()
 Converter::setTemplateBase()
 Converter::setTemplateDir()
 Converter::sortPageContentsByElementType()
 Converter::sourceLine()
 Converter::startHighlight()
 Converter::TranslateEntity()
 Converter::TranslateTag()
 Converter::TutorialExample()
 Converter::type_adjust()
 Converter::unmangle()
 Converter::vardump_tree()
 Converter::Varize()
 Converter::walk()
 Converter::walk_everything()
 Converter::writeExample()
 Converter::writeFile()
 Converter::writeSource()
 Converter::_rmdir()
 Converter::_setHighlightCache()
 Converter::_tutorial_path()

Documentation generated on Mon, 05 Dec 2011 21:40:16 -0600 by phpDocumentor 1.4.4