Converters
[ class tree: Converters ] [ index: Converters ] [ all elements ]

Class: PDFdefaultConverter

Source Location: /phpDocumentor/Converters/PDF/default/PDFdefaultConverter.inc

Class Overview

Converter
   |
   --PDFdefaultConverter

PDF output converter.


Author(s):

Version:

  • $Id: PDFdefaultConverter.inc 236747 2007-05-31 02:02:42Z ashnazg $

Variables

Methods


Inherited Variables

Inherited Methods

Class: Converter

Converter::Converter()
Initialize Converter data structures
Converter::AttrToString()
Convert the attribute of a Tutorial docbook tag's attribute list
Converter::Bolden()
Used to convert the contents of <b> in a docblock
Converter::Br()
Used to convert <br> in a docblock
Converter::checkState()
Compare parserStringWithInlineTags::Convert() cache state to $state
Converter::cleanup()
Finish up parsing/cleanup directories
Converter::Convert()
Convert all elements to output format
Converter::convertClass()
Default Class Handler
Converter::convertConst()
Converts class constants for template output.
Converter::convertDefine()
Converts defines for template output
Converter::ConvertErrorLog()
Convert the phpDocumentor parsing/conversion error log
Converter::convertFunction()
Converts function for template output
Converter::convertGlobal()
Converts global variables for template output
Converter::convertInclude()
Converts includes for template output
Converter::convertMethod()
Converts method for template output
Converter::convertPage()
Default Page Handler
Converter::ConvertTitle()
Convert the title of a Tutorial docbook tag section
Converter::ConvertTodoList()
Convert the list of all @todo tags
Converter::convertTutorial()
Default Tutorial Handler
Converter::convertVar()
Converts class variables for template output.
Converter::Convert_RIC()
Convert README/INSTALL/CHANGELOG file contents to output format
Converter::copyFile()
Copies a file from the template directory to the target directory
Converter::createParentDir()
Recursively creates all subdirectories that don't exist in the $dir path
Converter::EncloseList()
Used to convert the contents of <ol> or <ul> in a docblock
Converter::EncloseParagraph()
Used to enclose a paragraph in a docblock
Converter::endClass()
Called by walk() while converting, when the last class element has been parsed.
Converter::endPage()
Called by walk() while converting, when the last procedural page element has been parsed.
Converter::exampleProgramExample()
Used to convert the {@example} inline tag in a docblock.
Converter::flushHighlightCache()
Return the close text for the current token
Converter::formatIndex()
Called by walk() while converting.
Converter::formatLeftIndex()
Called by walk() while converting.
Converter::formatPkgIndex()
Called by walk() while converting.
Converter::formatTutorialTOC()
Creates a table of contents for a {@toc} inline tag in a tutorial
Converter::generateChildClassList()
returns a list of child classes
Converter::generateFormattedClassTree()
returns an array containing the class inheritance tree from the root object to the class.
Converter::getClassesOnPage()
gets a list of all classes declared on a procedural page represented by
Converter::getClassLink()
return false or a classLink to $expr
Converter::getConstLink()
return false or a constLink to $expr in $class
Converter::getConverterDir()
Get the absolute path to the converter's base directory
Converter::getCurrentPageLink()
Converter::getCurrentPageURL()
Return the path to the current
Converter::getDefineLink()
return false or a defineLink to $expr
Converter::getFileSourceName()
Translate the path info into a unique file name for the highlighted source code.
Converter::getFileSourcePath()
Return the fixed path to the source-code file folder.
Converter::getFormattedConflicts()
Converter::getFormattedDescMethods()
Get a list of methods in child classes that override this method
Converter::getFormattedDescVars()
Get a list of vars in child classes that override this var
Converter::getFormattedImplements()
returns an array containing the class inheritance tree from the root object to the class.
Converter::getFormattedInheritedConsts()
Return template-enabled list of inherited class constants
Converter::getFormattedInheritedMethods()
Return template-enabled list of inherited methods
Converter::getFormattedInheritedVars()
Return template-enabled list of inherited variables
Converter::getFormattedMethodImplements()
Get the method this method(s) implemented from an interface, if any
Converter::getFormattedOverrides()
Get the method this method overrides, if any
Converter::getFunctionLink()
return false or a functionLink to $expr
Converter::getGlobalLink()
return false or a globalLink to $expr
Converter::getGlobalValue()
Parse a global variable's default value for class initialization.
Converter::getHighlightState()
Converter::getId()
take abstractLink descendant and text $eltext and return a
Converter::getIncludeValue()
Parse an include's file to see if it is a file documented in this project
Converter::getLink()
The meat of the @see tag and inline {@link} tag
Converter::getMethodLink()
return false or a methodLink to $expr in $class
Converter::getPageLink()
return false or a pageLink to $expr
Converter::getSortedClassTreeFromClass()
Return a tree of all classes that extend this class
Converter::getSourceLink()
Converter::getState()
Return parserStringWithInlineTags::Convert() cache state
Converter::getTutorialId()
Return a converter-specific id to distinguish tutorials and their sections
Converter::getTutorialLink()
The meat of the @tutorial tag and inline {@tutorial} tag
Converter::getTutorialTree()
Get a tree structure representing the hierarchy of tutorials
Converter::getVarLink()
return false or a varLink to $expr in $class
Converter::hasSourceCode()
Determine whether an element's file has generated source code, used for linking to line numbers of source.
Converter::hasTutorial()
Converter::highlightDocBlockSource()
Used to allow converters to format the source code of DocBlocks the way they'd like.
Converter::highlightSource()
Used to allow converters to format the source code the way they'd like.
Converter::highlightTutorialSource()
Used to allow converters to format the source code of Tutorial XML the way they'd like.
Converter::Italicize()
Used to convert the contents of <i> in a docblock
Converter::Kbdize()
Used to convert the contents of <kbd> in a docblock
Converter::ListItem()
Used to convert the contents of <li> in a docblock
Converter::newSmarty()
Return a Smarty template object to operate with
Converter::Output()
do all necessary output
Converter::postProcess()
This version does nothing
Converter::prepareDocBlock()
convert the element's DocBlock for output
Converter::PreserveWhiteSpace()
Used to convert the contents of <pre> in a docblock
Converter::ProgramExample()
Used to convert the <code> tag in a docblock
Converter::returnLink()
take URL $link and text $text and return a link in the format needed for the Converter
Converter::returnSee()
take abstractLink descendant and text $eltext and return a link
Converter::Sampize()
Used to convert the contents of <samp> in a docblock
Converter::setSourcePaths()
Mark a file as having had source code highlighted
Converter::setTargetDir()
Sets the output directory for generated documentation
Converter::setTemplateBase()
Set the template directory with a different template base directory
Converter::setTemplateDir()
sets the template directory based on the $outputformat and $name
Converter::sortPageContentsByElementType()
sorts $page_contents by element type as well as alphabetically
Converter::sourceLine()
Return a line of highlighted source code with formatted line number
Converter::startHighlight()
Initialize highlight caching
Converter::TranslateEntity()
Used to translate an XML DocBook entity like &rdquo; from a tutorial by reading the options.ini file for the template.
Converter::TranslateTag()
Used to translate an XML DocBook tag from a tutorial by reading the options.ini file for the template.
Converter::TutorialExample()
Converter::type_adjust()
Called by parserReturnTag::Convert() to allow converters to change type names to desired formatting
Converter::unmangle()
Called by parserSourceInlineTag::stringConvert() to allow converters to format the source code the way they'd like.
Converter::vardump_tree()
Debugging function for dumping $tutorial_tree
Converter::Varize()
Used to convert the contents of <var> in a docblock
Converter::walk()
called by phpDocumentor_IntermediateParser::Convert() to traverse the array of pages and their elements, converting them to the output format
Converter::walk_everything()
walk over elements by package rather than page
Converter::writeExample()
Write out the formatted source code for an example php file
Converter::writeFile()
Writes a file to target dir
Converter::writeSource()
Write out the formatted source code for a php file
Converter::_rmdir()
Completely remove a directory and its contents
Converter::_setHighlightCache()
Converter::_tutorial_path()
Returns the path to this tutorial as a string

Class Details

[line 55]
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




Tags:

author:  Greg Beaver <cellog@php.net>
version:  $Id: PDFdefaultConverter.inc 236747 2007-05-31 02:02:42Z ashnazg $
todo:  Implement links to conflicts/inheritance
since:  1.1


[ Top ]


Class Variables

$classpackage_pagenums = array()

[line 65]


Type:  mixed


[ Top ]

$curclasspackage =  false

[line 71]


Type:  mixed


[ Top ]

$curpagepackage =  false

[line 70]


Type:  mixed


[ Top ]

$leftindex = array('classes' => false, 'pages' => false, 'functions' => false, 'defines' => false, 'globals' => false)

[line 63]


Type:  mixed
Overrides:  Array


[ Top ]

$name =  'default'

[line 69]



Tags:

var:  always default

Type:  string


[ Top ]

$outputformat =  'PDF'

[line 67]



Tags:

var:  always PDF

Type:  string
Overrides:  Array


[ Top ]

$pagepackage_pagenums = array()

[line 64]


Type:  mixed


[ Top ]

$pdf =  false

[line 76]


Type:  Cezpdf


[ Top ]

$ric_set = array()

[line 77]


Type:  mixed


[ Top ]

$smarty_dir =

[line 72]


Type:  mixed
Overrides:  Array


[ Top ]

$sort_absolutely_everything =  true

[line 62]

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



Tags:


Type:  boolean
Overrides:  Array


[ Top ]

$_sourcecode =

[line 84]

Source files for appendix C are stored here

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



Type:  array


[ Top ]



Class Methods


constructor PDFdefaultConverter [line 88]

PDFdefaultConverter PDFdefaultConverter( &$allp, &$packp, &$classes, &$procpages, $po, $pp, $qm, $targetDir, $templateDir, $title)



Tags:



Parameters:

  &$allp 
  &$packp 
  &$classes 
  &$procpages 
  $po 
  $pp 
  $qm 
  $targetDir 
  $templateDir 
  $title 

[ Top ]

method convertClass [line 461]

void convertClass( &$element)



Overrides Converter::convertClass() (Default Class Handler)

Parameters:

  &$element 

[ Top ]

method convertConst [line 439]

void convertConst( &$element)



Overrides Converter::convertConst() (Converts class constants for template output.)

Parameters:

  &$element 

[ Top ]

method convertDefine [line 541]

void convertDefine( &$element)



Overrides Converter::convertDefine() (Converts defines for template output)

Parameters:

  &$element 

[ Top ]

method convertDocBlock [line 249]

void convertDocBlock( &$element)



Parameters:

  &$element 

[ Top ]

method convertFunction [line 508]

void convertFunction( &$element)



Overrides Converter::convertFunction() (Converts function for template output)

Parameters:

  &$element 

[ Top ]

method convertGlobal [line 349]

void convertGlobal( &$element)



Overrides Converter::convertGlobal() (Converts global variables for template output)

Parameters:

  &$element 

[ Top ]

method convertInclude [line 494]

void convertInclude( &$element)



Overrides Converter::convertInclude() (Converts includes for template output)

Parameters:

  &$element 

[ Top ]

method convertMethod [line 376]

void convertMethod( &$element)



Overrides Converter::convertMethod() (Converts method for template output)

Parameters:

  &$element 

[ Top ]

method convertPackagepage [line 638]

void convertPackagepage( &$element)



Tags:

deprecated:  html package pages just don't work with PDF, use phpDocumentor Tutorials


Parameters:

  &$element 

[ Top ]

method convertPage [line 562]

void convertPage( &$element)



Overrides Converter::convertPage() (Default Page Handler)

Parameters:

  &$element 

[ Top ]

method convertParams [line 331]

void convertParams( &$element)



Parameters:

  &$element 

[ Top ]

method convertTutorial [line 645]

void convertTutorial( &$element)



Overrides Converter::convertTutorial() (Default Tutorial Handler)

Parameters:

  &$element 

[ Top ]

method convertVar [line 416]

void convertVar( &$element)



Overrides Converter::convertVar() (Converts class variables for template output.)

Parameters:

  &$element 

[ Top ]

method Convert_RIC [line 244]

void Convert_RIC( README|INSTALL|CHANGELOG $name, string $contents)

Convert README/INSTALL/CHANGELOG file contents to output format



Overrides Converter::Convert_RIC() (Convert README/INSTALL/CHANGELOG file contents to output format)

Parameters:

README|INSTALL|CHANGELOG  $name 
string  $contents  contents of the file

[ Top ]

method generateFormattedClassTrees [line 665]

void generateFormattedClassTrees( string $package)

returns a template-enabled array of class trees



Tags:



Parameters:

string  $package  package to generate a class tree for

[ Top ]

method getCData [line 630]

void getCData( $value)



Parameters:

  $value 

[ Top ]

method getClassLink [line 843]

mixed getClassLink( string $expr, string $package, [string $file = false], [ $text = false])



Tags:

return:  false if not found, or an html a link to the class's documentation
see:  Converter::getClassLink()


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)
  $text 

[ Top ]

method getConstLink [line 953]

mixed getConstLink( string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)



Tags:

return:  false if not found, or an html a link to the var's documentation
see:  Converter::getConstLink()


Overrides Converter::getConstLink() (return false or a constLink to $expr in $class)

Parameters:

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

[ Top ]

method getDefineLink [line 873]

mixed getDefineLink( string $expr, string $package, [string $file = false], [boolean $text = false])



Tags:

return:  false if not found, or an html a link to the define's documentation
see:  Converter::getDefineLink()


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

[ Top ]

method getExampleLink [line 140]

void getExampleLink( $path, $title)



Parameters:

  $path 
  $title 

[ Top ]

method getFileSourceName [line 152]

void getFileSourceName( $path, [ $anchor = ''])



Overrides Converter::getFileSourceName() (Translate the path info into a unique file name for the highlighted source code.)

Parameters:

  $path 
  $anchor 

[ Top ]

method getFunctionLink [line 858]

mixed getFunctionLink( string $expr, string $package, [string $file = false], [boolean $text = false])



Tags:

return:  false if not found, or an html a link to the function's documentation
see:  Converter::getFunctionLink()


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

[ Top ]

method getGlobalLink [line 888]

mixed getGlobalLink( string $expr, string $package, [string $file = false], [boolean $text = false])



Tags:

return:  false if not found, or an html a link to the global variable's documentation
see:  Converter::getGlobalLink()


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

[ Top ]

method getGlobalValue [line 371]

void getGlobalValue( $value)



Overrides Converter::getGlobalValue() (Parse a global variable's default value for class initialization.)

Parameters:

  $value 

[ Top ]

method getMethodLink [line 919]

mixed getMethodLink( string $expr, string $class, string $package, [string $file = false], [boolean $text = false])



Tags:

return:  false if not found, or an html a link to the method's documentation
see:  Converter::getMethodLink()


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

[ Top ]

method getPageLink [line 903]

mixed getPageLink( string $expr, string $package, [string $path = false], [boolean $text = false])



Tags:

return:  false if not found, or an html a link to the procedural page's documentation
see:  Converter::getPageLink()


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

[ Top ]

method getPageName [line 619]

void getPageName( &$element)



Parameters:

  &$element 

[ Top ]

method getRootTree [line 684]

string getRootTree( array $tree, $package)

return formatted class tree for the Class Trees page



Tags:

see:  Classes::$definitechild, PDFdefaultConverter::generateFormattedClassTrees()


Parameters:

array  $tree  output from getSortedClassTreeFromClass()
  $package 

[ Top ]

method getSourceAnchor [line 167]

string getSourceAnchor( string $sourcefile, string $anchor, [string $text = ''], [boolean $link = false])

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



Tags:

return:  link to an anchor, or the anchor


Parameters:

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

[ Top ]

method getSourceLink [line 146]

void getSourceLink( $path)



Overrides Converter::getSourceLink() (parent method not documented)

Parameters:

  $path 

[ Top ]

method getState [line 967]

1 getState( )



Tags:

return:  always the same


Overrides Converter::getState() (Return parserStringWithInlineTags::Convert() cache state)

[ Top ]

method getTutorialId [line 625]

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 

[ Top ]

method getVarLink [line 936]

mixed getVarLink( string $expr, string $class, string $package, [string $file = false], [boolean $text = false], boolean 5)



Tags:

return:  false if not found, or an html a link to the var's documentation
see:  Converter::getVarLink()


Overrides Converter::getVarLink() (return false or a varLink to $expr in $class)

Parameters:

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

[ Top ]

method mystrnatcasecmp [line 830]

void mystrnatcasecmp( $a, $b)



Parameters:

  $a 
  $b 

[ Top ]

method Output [line 751]

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

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



Overrides Converter::Output() (do all necessary output)

Parameters:

  $title 

[ Top ]

method postProcess [line 121]

void postProcess( $text)



Overrides Converter::postProcess() (This version does nothing)

Parameters:

  $text 

[ Top ]

method returnLink [line 234]

string returnLink( string $link, string $text)



Tags:

return:  <c:alink:$link>$text</c:alink>


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 

[ Top ]

method returnSee [line 184]

void returnSee( abstractLink &$element, [string $eltext = false])

Returns a bookmark using Cezpdf 009



Overrides Converter::returnSee() (take abstractLink descendant and text $eltext and return a link)

Parameters:

abstractLink  &$element  a descendant of abstractlink should be passed, and never text
string  $eltext  text to display in the link

[ Top ]

method setTemplateDir [line 960]

void setTemplateDir( $dir)



Overrides Converter::setTemplateDir() (sets the template directory based on the $outputformat and $name)

Parameters:

  $dir 

[ Top ]

method TranslateTag [line 602]

string TranslateTag( string $name, string $attr, string $cdata, string $unconvertedcdata)

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



Overrides Converter::TranslateTag() (Used to translate an XML DocBook tag from a tutorial by reading the options.ini file for the template.)

Parameters:

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

[ Top ]

method unmangle [line 975]

void unmangle( $notused, $source)



Tags:



Overrides Converter::unmangle() (Called by parserSourceInlineTag::stringConvert() to allow converters to format the source code the way they'd like.)

Parameters:

  $notused 
  $source 

[ Top ]

method writeExample [line 126]

void writeExample( $title, $path, $source)



Overrides Converter::writeExample() (Write out the formatted source code for an example php file)

Parameters:

  $title 
  $path 
  $source 

[ Top ]

method writeSource [line 106]

void writeSource( $path, $value)



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

Parameters:

  $path 
  $value 

[ Top ]

    Поддержать сайт на родительском проекте КГБ