src/Entity/Mail.php
protected function initAddress(array $address, $field)
    {
        $this->{$this->methodName('clear', $field)}();

        foreach ($address as $email => $label) {
            if (is_int($email)) {
                $email = $label;
            }

            $this->{$this->methodName('add', $field)}($email, $label);
        }
    }
protected function initAddress(array $address, $field)
    {
        $this->{$this->methodName('clear', $field)}();

        foreach ($address as $email => $label) {
            if (is_int($email)) {
                $email = $label;
            }

            $this->{$this->methodName('add', $field)}($email, $label);
        }
    }
protected function initAddress ( array $ address , $ field ) { $ this -> { $ this -> methodName ( 'clear' , $ field ) } ( ) ; foreach ( $ address as $ email => $ label ) { if ( is_int ( $ email ) ) { $ email = $ label ; } $ this -> { $ this -> methodName ( 'add' , $ field ) } ( $ email , $ label ) ; } }
Set address purpose property

@param array  $address
@param string $field
Set address purpose property