class FactoryCommandLoader implements CommandLoaderInterface

A simple command loader using factories to instantiate commands lazily.

Methods

__construct(array $factories)

No description

bool
has(string $name)

Checks if a command exists.

get(string $name)

Loads a command.

string[]
getNames()

No description

Details

at line line 28
__construct(array $factories)

Parameters

array $factories Indexed by command names

at line line 36
bool has(string $name)

Checks if a command exists.

Parameters

string $name

Return Value

bool

at line line 44
Command get(string $name)

Loads a command.

Parameters

string $name

Return Value

Command

Exceptions

CommandNotFoundException

at line line 58
string[] getNames()

Return Value

string[] All registered command names