示例#1
0
 /**
  *  Tell whether any generic URI is valid
  *
  * @return bool
  */
 protected function isValidGenericUri()
 {
     $path = $this->path->getUriComponent();
     if (false === strpos($path, ':')) {
         return true;
     }
     $path = explode(':', $path);
     $path = array_shift($path);
     $str = $this->scheme->getUriComponent() . $this->getAuthority();
     return !(empty($str) && strpos($path, '/') === false);
 }