/**
  * @deprecated
  */
 public static function fromParams(UrlParams $params)
 {
     if ($params->has('service') && $params->has('host')) {
         return new Service(MonitoringBackend::instance(), $params->get('host'), $params->get('service'));
     } elseif ($params->has('host')) {
         return new Host(MonitoringBackend::instance(), $params->get('host'));
     }
     return null;
 }
Exemple #2
0
 /**
  * Return true if a urls' query parameter exists, otherwise false
  *
  * @param   string  $param    The url parameter name to check
  *
  * @return  bool
  */
 public function hasParam($param)
 {
     return $this->params->has($param);
 }