public function setState($state)
    {
        $oldState = $this->getState();

        if ($oldState === $state) {
            return $this;
        }

        $this->getLogger()->debug('Changing state from: '.$oldState.' to: '.$state.'.');
        $this->state = $state;

        return $this;
    }