src/Sulu/Component/Webspace/Portal.php
public function setEnvironments(array $environments)
    {
        $this->environments = [];

        foreach ($environments as $environment) {
            $this->addEnvironment($environment);
        }
    }
public function setEnvironments(array $environments)
    {
        $this->environments = [];

        foreach ($environments as $environment) {
            $this->addEnvironment($environment);
        }
    }
public function setEnvironments ( array $ environments ) { $ this -> environments = [ ] ; foreach ( $ environments as $ environment ) { $ this -> addEnvironment ( $ environment ) ; } }
Sets the environments for this portal.

@param \Sulu\Component\Webspace\Environment[] $environments
Sets the environments for this portal .