PHP Class SM\Factory\AbstractFactory

Inheritance: implements SM\Factory\ClearableFactoryInterface
Afficher le fichier Open project: winzou/state-machine Class Usage Examples

Protected Properties

Свойство Type Description
$configs array
$stateMachines array

Méthodes publiques

Méthode Description
__construct ( array $configs )
addConfig ( array $config, string $graph = 'default' ) Adds a new config
clear ( ) {@inheritDoc}
get ( $object, $graph = 'default' ) {@inheritDoc}

Méthodes protégées

Méthode Description
createStateMachine ( $object, array $config ) : SM\StateMachine\StateMachineInterface Create a state machine for the given object and config

Method Details

__construct() public méthode

public __construct ( array $configs )
$configs array Array of configs for the available state machines

addConfig() public méthode

Adds a new config
public addConfig ( array $config, string $graph = 'default' )
$config array
$graph string

clear() public méthode

{@inheritDoc}
public clear ( )

createStateMachine() abstract protected méthode

Create a state machine for the given object and config
abstract protected createStateMachine ( $object, array $config ) : SM\StateMachine\StateMachineInterface
$object
$config array
Résultat SM\StateMachine\StateMachineInterface

get() public méthode

{@inheritDoc}
public get ( $object, $graph = 'default' )

Property Details

$configs protected_oe property

protected array $configs
Résultat array

$stateMachines protected_oe property

protected array $stateMachines
Résultat array