src/SM/Factory/AbstractFactory.php
public function addConfig(array $config, $graph = 'default')
    {
        if (!isset($config['graph'])) {
            $config['graph'] = $graph;
        }

        if (!isset($config['class'])) {
            throw new SMException(sprintf(
               'Index "class" needed for the state machine configuration of graph "%s"',
                $config['graph']
            ));
        }

        $this->configs[] = $config;
    }
public function addConfig(array $config, $graph = 'default')
    {
        if (!isset($config['graph'])) {
            $config['graph'] = $graph;
        }

        if (!isset($config['class'])) {
            throw new SMException(sprintf(
               'Index "class" needed for the state machine configuration of graph "%s"',
                $config['graph']
            ));
        }

        $this->configs[] = $config;
    }
public function addConfig ( array $ config , $ graph = 'default' ) { if ( ! isset ( $ config [ 'graph' ] ) ) { $ config [ 'graph' ] = $ graph ; } if ( ! isset ( $ config [ 'class' ] ) ) { throw new SMException ( sprintf ( 'Index "class" needed for the state machine configuration of graph "%s"' , $ config [ 'graph' ] ) ) ; } $ this -> configs [ ] = $ config ; }
Adds a new config

@param array  $config
@param string $graph

@throws SMException If the index "class" is not configured
Adds a new config