src/Form/Element.php
public function setAttributes(array $attributes = [])
    {
        $this->attributes = array_merge($this->attributes, $attributes);

        $this->validateAttributes();

        $this->decoupleOptionsFromAttributes();

        return $this;
    }
public function setAttributes(array $attributes = [])
    {
        $this->attributes = array_merge($this->attributes, $attributes);

        $this->validateAttributes();

        $this->decoupleOptionsFromAttributes();

        return $this;
    }
public function setAttributes ( array $ attributes = [ ] ) { $ this -> attributes = array_merge ( $ this -> attributes , $ attributes ) ; $ this -> validateAttributes ( ) ; $ this -> decoupleOptionsFromAttributes ( ) ; return $ this ; }
Init element from set of attributes.

@param array $attributes

@return $this
Init element from set of attributes .