Skip to content

Latest commit

 

History

History
136 lines (48 loc) · 1.14 KB

FactoryCommandLoader.md

File metadata and controls

136 lines (48 loc) · 1.14 KB

FactoryCommandLoader

A simple command loader using factories to instantiate commands lazily.

Properties

factories

private $factories

Methods

__construct

public __construct(callable[] $factories): mixed

Parameters:

Parameter Type Description
$factories callable[] Indexed by command names

has

Checks if a command exists.

public has(string $name): bool

Parameters:

Parameter Type Description
$name string

get

Loads a command.

public get(string $name): \Symfony\Component\Console\Command\Command

Parameters:

Parameter Type Description
$name string

getNames

public getNames(): string[]