interface Kernel (View source)

Represents the core state of a SilverStripe application Based loosely on symfony/http-kernel's KernelInterface component

Constants

TEST

Test environment

DEV

Dev environment

LIVE

Live (default) environment

Methods

public
boot($flush = false)

No description

public
shutdown()

Shutdowns the kernel.

public
nest()

Nests this kernel, all components, and returns the nested value.

public
$this
activate()

Ensures this kernel is the active kernel after or during nesting

public
getContainer()

No description

public
getClassLoader()

No description

public
$this
setClassLoader(ClassLoader $classLoader)

No description

public
getInjectorLoader()

Get loader for injector instance

public
$this
setInjectorLoader(InjectorLoader $injectorLoader)

No description

public
getModuleLoader()

No description

public
$this
setModuleLoader(ModuleLoader $moduleLoader)

No description

public
getConfigLoader()

No description

public
$this
setConfigLoader(ConfigLoader $configLoader)

No description

public
$this
setThemeResourceLoader(ThemeResourceLoader $themeResourceLoader)

No description

public
string
getEnvironment()

One of dev, live, or test

public
$this
setEnvironment(string $environment)

Sets new environment

public
bool|null
isFlushed()

Returns whether the Kernel has been flushed on boot

Details

boot($flush = false)

No description

Parameters

$flush

shutdown()

Shutdowns the kernel.

Kernel nest()

Nests this kernel, all components, and returns the nested value.

Return Value

Kernel

$this activate()

Ensures this kernel is the active kernel after or during nesting

Return Value

$this

Injector getContainer()

No description

Return Value

Injector

ClassLoader getClassLoader()

No description

Return Value

ClassLoader

$this setClassLoader(ClassLoader $classLoader)

No description

Parameters

ClassLoader $classLoader

Return Value

$this

InjectorLoader getInjectorLoader()

Get loader for injector instance

Return Value

InjectorLoader

$this setInjectorLoader(InjectorLoader $injectorLoader)

No description

Parameters

InjectorLoader $injectorLoader

Return Value

$this

ModuleLoader getModuleLoader()

No description

Return Value

ModuleLoader

$this setModuleLoader(ModuleLoader $moduleLoader)

No description

Parameters

ModuleLoader $moduleLoader

Return Value

$this

ConfigLoader getConfigLoader()

No description

Return Value

ConfigLoader

$this setConfigLoader(ConfigLoader $configLoader)

No description

Parameters

ConfigLoader $configLoader

Return Value

$this

ThemeResourceLoader getThemeResourceLoader()

No description

Return Value

ThemeResourceLoader

$this setThemeResourceLoader(ThemeResourceLoader $themeResourceLoader)

No description

Parameters

ThemeResourceLoader $themeResourceLoader

Return Value

$this

string getEnvironment()

One of dev, live, or test

Return Value

string

$this setEnvironment(string $environment)

Sets new environment

Parameters

string $environment

Return Value

$this

bool|null isFlushed()

Returns whether the Kernel has been flushed on boot

Return Value

bool|null

null if the kernel hasn't been booted yet