public function setElectronicAddresses(Collection $electronicAddresses)
    {
        if ($this->primaryElectronicAddress !== null && !$this->electronicAddresses->contains($this->primaryElectronicAddress)) {
            $this->primaryElectronicAddress = null;
        }
        $this->electronicAddresses = $electronicAddresses;
    }
public function setElectronicAddresses(Collection $electronicAddresses)
    {
        if ($this->primaryElectronicAddress !== null && !$this->electronicAddresses->contains($this->primaryElectronicAddress)) {
            $this->primaryElectronicAddress = null;
        }
        $this->electronicAddresses = $electronicAddresses;
    }
public function setElectronicAddresses ( Collection $ electronicAddresses ) { if ( $ this -> primaryElectronicAddress !== null && ! $ this -> electronicAddresses -> contains ( $ this -> primaryElectronicAddress ) ) { $ this -> primaryElectronicAddress = null ; } $ this -> electronicAddresses = $ electronicAddresses ; }
Sets the electronic addresses of this person.

@param \Doctrine\Common\Collections\Collection<\Neos\Party\Domain\Model\ElectronicAddress> $electronicAddresses
@return void
Sets the electronic addresses of this person .