src/Bag.php
public function set($name, $value = null)
    {
        if (is_array($name)) {
            $this->parameters = array_replace($this->parameters, $name);
        } else {
            $this->parameters[trim(strtolower($name))] = is_string($value) ? trim($value) : $value;
        }
    }
public function set($name, $value = null)
    {
        if (is_array($name)) {
            $this->parameters = array_replace($this->parameters, $name);
        } else {
            $this->parameters[trim(strtolower($name))] = is_string($value) ? trim($value) : $value;
        }
    }
public function set ( $ name , $ value = null ) { if ( is_array ( $ name ) ) { $ this -> parameters = array_replace ( $ this -> parameters , $ name ) ; } else { $ this -> parameters [ trim ( strtolower ( $ name ) ) ] = is_string ( $ value ) ? trim ( $ value ) : $ value ; } }
Save a value

@param string|array $name  Name of the value
@param mixed        $value The value to save
Save a value