src/main/php/routing/Route.php
public function matches(CalledUri $calledUri): bool
    {
        if (!$this->matchesPath($calledUri)) {
            return false;
        }

        if (in_array($calledUri->method(), $this->allowedRequestMethods)) {
            return true;
        }

        if (in_array(Http::GET, $this->allowedRequestMethods)) {
            return $calledUri->methodEquals(Http::HEAD);
        }

        return false;
    }
public function matches(CalledUri $calledUri): bool
    {
        if (!$this->matchesPath($calledUri)) {
            return false;
        }

        if (in_array($calledUri->method(), $this->allowedRequestMethods)) {
            return true;
        }

        if (in_array(Http::GET, $this->allowedRequestMethods)) {
            return $calledUri->methodEquals(Http::HEAD);
        }

        return false;
    }
public function matches ( CalledUri $ calledUri ) : bool { if ( ! $ this -> matchesPath ( $ calledUri ) ) { return false ; } if ( in_array ( $ calledUri -> method ( ) , $ this -> allowedRequestMethods ) ) { return true ; } if ( in_array ( Http :: GET , $ this -> allowedRequestMethods ) ) { return $ calledUri -> methodEquals ( Http :: HEAD ) ; } return false ; }
checks if this route is applicable for given request

@param   \stubbles\webapp\CalledUri  $calledUri  current request uri
@return  bool
checks if this route is applicable for given request