public function toggleImporter($key)
    {
        $importer = $this->getImporter($key);
        $importer->toggle();
        foreach ($importer->getSegments() as $segment) {
            if ($importer->isEnabled()) {
                $this->addSegment($segment);
            } else {
                $this->removeSegment($segment);
            }
        }
    }
public function toggleImporter($key)
    {
        $importer = $this->getImporter($key);
        $importer->toggle();
        foreach ($importer->getSegments() as $segment) {
            if ($importer->isEnabled()) {
                $this->addSegment($segment);
            } else {
                $this->removeSegment($segment);
            }
        }
    }
public function toggleImporter ( $ key ) { $ importer = $ this -> getImporter ( $ key ) ; $ importer -> toggle ( ) ; foreach ( $ importer -> getSegments ( ) as $ segment ) { if ( $ importer -> isEnabled ( ) ) { $ this -> addSegment ( $ segment ) ; } else { $ this -> removeSegment ( $ segment ) ; } } }
Toggles an importer and its segments

@param   string $key
Toggles an importer and its segments