public function getParam($key)
{
if (method_exists($this, 'get' . $key)) {
return $this->{'get' . $key}();
}
// always use uppercase
$key = strtoupper($key);
if (!array_key_exists($key, $this->parameters)) {
throw new InvalidArgumentException('Parameter ' . $key . ' does not exist.');
}
return $this->parameters[$key];
}