Application
class Application extends Application
Web application.
Properties
static protected Application | $instance | Singleton instance of self. | from Application |
protected float | $startTime | Application start time. | from Application |
protected Container | $container | Container. | from Application |
protected Config | $config | Config instance. | from Application |
protected string | $charset | Application charset. | from Application |
protected string | $language | Application language. | from Application |
protected string | $applicationPath | Application path. | from Application |
protected string | $storagePath | Application storage path. | from Application |
protected array | $packages | Booted packages. | from Application |
Methods
Starts the application and returns a singleton instance of the application.
Returns the Mako environment. NULL is returned if no environment is specified.
Runs the application.
Details
in Application at line 101
__construct(string $applicationPath)
Constructor.
in Application at line 115
static Application
start(string $applicationPath)
Starts the application and returns a singleton instance of the application.
in Application at line 132
static Application
instance()
Returns a singleton instance of the application.
in Application at line 147
float
getStartTime()
Returns the application start time.
in Application at line 157
Container
getContainer()
Returns the container instance.
in Application at line 167
Config
getConfig()
Returns the config instance.
in Application at line 177
string
getCharset()
Returns the application charset.
in Application at line 187
string
getLanguage()
Returns the application language.
in Application at line 197
setLanguage(array $language)
Sets the application language settings.
in Application at line 212
string
getPath()
Gets the application path.
in Application at line 222
string
getStoragePath()
Gets the application storage path.
in Application at line 232
array
getPackages()
Returns all the application packages.
in Application at line 243
Package
getPackage(string $package)
Returns a package by its name.
in Application at line 259
string
getNamespace(bool $prefix = false)
Returns the application namespace.
in Application at line 276
bool
isCommandLine()
Is the application running in the CLI?
in Application at line 286
string|null
getEnvironment()
Returns the Mako environment. NULL is returned if no environment is specified.
in Application at line 294
protected
configure()
Configure.
in Application at line 326
protected
serviceRegistrar(string $type)
Registers services in the container.
in Application at line 337
protected
registerCLIServices()
Registers command line services.
in Application at line 345
protected
registerWebServices()
Registers web services.
in Application at line 353
protected
registerServices()
Register services in the container.
in Application at line 374
protected
bootstrap()
Loads the application bootstrap file.
in Application at line 387
protected
packageBooter(string $type)
Boots packages.
in Application at line 402
protected
bootCliPackages()
Boots command line packages.
in Application at line 410
protected
bootWebPackages()
Boots web packages.
in Application at line 418
protected
bootPackages()
Boot packages.
in Application at line 439
protected Container
containerFactory()
Creates a container instance.
in Application at line 449
protected Config
configFactory()
Creates a configuration instance.
in Application at line 457
protected
initialize()
Sets up the framework core.
in Application at line 485
$this
boot()
Boots the application.
at line 26
run()
Runs the application.