__construct()
addTemplate()
copyRecursive()
debug()
dispatch()
execute()
findExternalClassDocumentLocation()
generateFilename()
getExternalClassDocs()
getExternalClassDocumentLocation()
getParseprivate()
getSource()
getTarget()
getTemplates()
getTemplatesPath()
getTransformations()
log()
setExternalClassDoc()
setExternalClassDocs()
setParseprivate()
setSource()
setTarget()
setTemplates()
setTemplatesPath()
$event_dispatcher
$behaviours
$external_class_docs
$parsePrivate
$source
$target
$templates
$templates_path
$transformations
Core class responsible for transforming the structure.xml file to a set of artifacts.
| category | phpDocumentor |
|---|---|
| package | Transformer |
| author | Mike van Riel |
| license | MIT |
| link | http://phpdoc.org |
__construct()
addTemplate(string $name) : void
stringName of the template to add.
copyRecursive(string $src, string $dst) : void
stringThe source location to copy
stringThe destination location to copy to
\Exception |
if $src does not exist or $dst is not writable |
|---|
debug(string $message) : void
| inherited_from | \phpDocumentor_Transformer_Abstract::debug() |
|---|
stringThe message to log.
dispatch(string $name, \string[] $arguments) : mixed | null
This method tries to dispatch an event; if no Event Dispatcher has been set than this method will explicitly not fail and return null. By not failing we make the Event Dispatcher optional and is it easier for people to re-use this component in their own application.
| inherited_from | \phpDocumentor_Transformer_Abstract::dispatch() |
|---|
stringName of the event to dispatch.
\string[]Arguments for this event.
\phpDocumentor_Parser_Exception |
if there is a dispatcher but it is not of type sfEventDispatcher |
|---|
mixednull
execute() : void
findExternalClassDocumentLocation(string $class) : null | string
stringFQCN to retrieve documentation URL for.
nullstring
generateFilename(string $name) : string
This method strips down the given $name using the following rules: * if the $name is postfixed with .php then that is removed * any occurance of \ or DIRECTORY_SEPARATOR is replaced with . * any dots that the name starts or ends with is removed * the result is postfixed with .html
stringName to convert.
stringgetExternalClassDocs() : \string[]
\string[]getExternalClassDocumentLocation(string $prefix, string $class) : string | null
stringClass prefix to retrieve a URL for.
stringIf provided will replace the {CLASS} param with this string.
stringnull
getParseprivate() : bool
boolgetTarget() : string
stringgetTemplates() : \string[]
\string[]getTemplatesPath() : string
stringgetTransformations() : \phpDocumentor_Transformer_Transformation[]
log(string $message, int $priority) : void
| inherited_from | \phpDocumentor_Transformer_Abstract::log() |
|---|
stringThe message to log.
intThe logging priority, the lower, the more important. Ranges from 1 to 7
setExternalClassDoc(string $prefix, string $uri) : void
Please note that the prefix string is matched against the start of the class name and that the preceding \ for namespaces should NOT be included. You can augment the URI with the name of the found class by inserting the param {CLASS}. By default the class is inserted as-is; to insert a lowercase variant use the parameter {LOWERCASE_CLASS}
stringClass prefix to match, i.e. Zend_Config_
stringURI to link to when above prefix is encountered.
setExternalClassDocs(\string[] $external_class_docs) : void
| see | \self::setExternalClassDoc() |
|---|
\string[]Array containing prefix => URI pairs.
setParseprivate(bool $val) : void
boolTrue if all needs to be shown, false otherwise.
setSource(string $source) : void
stringThe location of the structure file as full path (may be relative).
\Exception |
if the source is not a valid readable file. |
|---|
setTarget(string $target) : void
stringThe target location where to output the artifacts.
\Exception |
if the target is not a valid writable directory. |
|---|
setTemplates(string | \string[] $template) : void
string\string[]Name or names of the templates.
setTemplatesPath(string $path) : void
stringAbsolute path where the templates are.
$event_dispatcher : \sfEventDispatcher | null
| inherited_from | \phpDocumentor_Transformer_Abstract::$$event_dispatcher |
|---|
$behaviours : \phpDocumentor_Transformer_Behaviour_Collection
$external_class_docs : string
What happens is that the transformer knows where to find external API docs for classes with a certain prefix. For example: having a prefix HTML_QuickForm2_ will link an unidentified class that starts with HTML_QuickForm2_ to a (defined) URL i.e. http://pear.php.net/package/HTML_QuickForm2/docs/ latest/HTML_QuickForm2/${class}.html
$parsePrivate : boolean
$target : string | null
$templates_path : string