Pheasant\Options::merge PHP Method

merge() public method

Merges a new array into the options structure
public merge ( $array, $default = true )
    public function merge($array, $default = true)
    {
        $newarray = array();
        foreach ($array as $key => $value) {
            $newKey = is_numeric($key) ? $value : $key;
            $newValue = is_numeric($key) ? true : $value;
            $newarray[$newKey] = $newValue;
        }
        $this->_options = array_merge($this->_options, $newarray);
        return $this;
    }