class PreconditionService (View source)

Service class for installation preconditions.

Properties

protected Application $app

The application instance.

protected Repository $config

The configuration repository.

Methods

__construct(Application $app, Repository $config)

Initializes the instance.

getPreconditions(bool $includeWebPreconditions = true)

Get the preconditions.

getPreconditionByHandle(string $handle)

Get a precondition given its handle.

getPreconditionByClassName(string $className)

Get a precondition given its fully-qualified class name.

Details

__construct(Application $app, Repository $config)

Initializes the instance.

Parameters

Application $app

the application instance

Repository $config

the configuration repository

PreconditionInterface[] getPreconditions(bool $includeWebPreconditions = true)

Get the preconditions.

Parameters

bool $includeWebPreconditions

Return Value

PreconditionInterface[]

PreconditionInterface getPreconditionByHandle(string $handle)

Get a precondition given its handle.

Parameters

string $handle

the precondition handle

Return Value

PreconditionInterface

Exceptions

Exception

PreconditionInterface getPreconditionByClassName(string $className)

Get a precondition given its fully-qualified class name.

Parameters

string $className

the fully-qualified class name of the precondition

Return Value

PreconditionInterface

Exceptions

Exception