src/Mordilion/Configurable/Configurable.php
public function setConfiguration($configuration, $configure = true)
    {
        if (!$configuration instanceof ConfigurationInterface) {
            $configuration = new Configuration($configuration);
        }

        unset($this->configuration); // destroy the old one

        $this->configuration = $configuration;

        if ($configure) {
            $this->configure();
        }
    }
public function setConfiguration($configuration, $configure = true)
    {
        if (!$configuration instanceof ConfigurationInterface) {
            $configuration = new Configuration($configuration);
        }

        unset($this->configuration); // destroy the old one

        $this->configuration = $configuration;

        if ($configure) {
            $this->configure();
        }
    }
public function setConfiguration ( $ configuration , $ configure = true ) { if ( ! $ configuration instanceof ConfigurationInterface ) { $ configuration = new Configuration ( $ configuration ) ; } unset ( $ this -> configuration ) ; // destroy the old one $ this -> configuration = $ configuration ; if ( $ configure ) { $ this -> configure ( ) ; } }
This method will configure the object with the provided configuration.

@param mixed $configuration
@param boolean $configure

@return void
This method will configure the object with the provided configuration .