Application

Extends \Cilex\Application

Application class for phpDocumentor.

Can be used as bootstrap when the run method is not invoked.

package

Default

Methods

Initializes all components used by phpDocumentor.

__construct(\Composer\Autoload\ClassLoader $autoloader = null, array $values = array()) 

Arguments

$autoloader

\Composer\Autoload\ClassLoader

$values

array

Adds the command to phpDocumentor that belong to the Phar namespace.

addCommandsForPharNamespace() : void

Adds the command to phpDocumentor that belong to the Project namespace.

addCommandsForProjectNamespace() : void

Adds the event dispatcher to phpDocumentor's container.

addEventDispatcher() : void

Adds a logging provider to the container of phpDocumentor.

addLogging() : void

Removes all logging handlers and replaces them with handlers that can write to the given logPath and level.

configureLogger(\Monolog\Logger $logger, integer $level, string $logPath = null) : void

Arguments

$logger

\Monolog\Logger

The logger instance that needs to be configured.

$level

integer

The minimum level that will be written to the normal logfile; matches one of the constants in {@see \Monolog\Logger}.

$logPath

string

The full path where the normal log file needs to be written.

Adjust php.ini settings.

defineIniSettings() : void

Run the application and if no command is provided, use project:run.

run(boolean $interactive = false) : void

Arguments

$interactive

boolean

Whether to run in interactive mode.

If the timezone is not set anywhere, set it to UTC.

setTimezone() : void

This is done to prevent any warnings being outputted in relation to using date/time functions. What is checked is php.ini, and if the PHP version is prior to 5.4, the TZ environment variable.

link

for more information how PHP determines the default timezone.

codeCoverageIgnore

this method is very hard, if not impossible, to unit test and not critical.

Properties

represents the version of phpDocumentor as stored in /VERSION

VERSION : string
static
var

represents the version of phpDocumentor as stored in /VERSION

Type(s)

string