public function set($key, $value, $subKey = null)
    {
        if (!is_null($subKey) && (is_array($this->data[$key]))) {
            $this->data[$key][$subKey] = $value;
        } else {
            $this->data[$key] = $value;
        }
    }
public function set($key, $value, $subKey = null)
    {
        if (!is_null($subKey) && (is_array($this->data[$key]))) {
            $this->data[$key][$subKey] = $value;
        } else {
            $this->data[$key] = $value;
        }
    }
public function set ( $ key , $ value , $ subKey = null ) { if ( ! is_null ( $ subKey ) && ( is_array ( $ this -> data [ $ key ] ) ) ) { $ this -> data [ $ key ] [ $ subKey ] = $ value ; } else { $ this -> data [ $ key ] = $ value ; } }
Sets value for specific key with optional subkey

@param string $key    The key to set value for
@param mixed  $value  The value to set
@param string $subKey The optional subKey to set value for

@return void
@Synchronized
Sets value for specific key with optional subkey