public function toggleSegment($key)
    {
        $segment = $this->getSegment($key);
        if (false === $segment->isEnabled()) {
            return $segment->enable();
        }
        return $segment->disable();
    }
public function toggleSegment($key)
    {
        $segment = $this->getSegment($key);
        if (false === $segment->isEnabled()) {
            return $segment->enable();
        }
        return $segment->disable();
    }
public function toggleSegment ( $ key ) { $ segment = $ this -> getSegment ( $ key ) ; if ( false === $ segment -> isEnabled ( ) ) { return $ segment -> enable ( ) ; } return $ segment -> disable ( ) ; }
Toggles a segment

@param   string $key
Toggles a segment