Tabnine Logo
Request.getMethod
Code IndexAdd Tabnine to your IDE (free)

How to use
getMethod
method
in
leap.web.Request

Best Java code snippets using leap.web.Request.getMethod (Showing top 6 results out of 1,395)

origin: org.leapframework/leap-websecurity

  protected final String getCacheKey(Request request){
    return request.getMethod() + "$" + request.getPath();
  }
}
origin: org.leapframework/leap-websecurity

  private String genCacheKey(Request request){
    return request.getMethod()+"$"+request.getPath();
  }
}
origin: org.leapframework/leap-websecurity

private boolean matches(SecuredPath p,Request request){
  return p.matches(request) &&
        (p.getRoute() == null ||
          Strings.equals(p.getRoute().getMethod(),"*") ||
          Strings.equalsIgnoreCase(p.getRoute().getMethod(),request.getMethod()));
}
origin: org.leapframework/leap-websecurity

protected final boolean matches(SecuredPath p, Request request){
  return p.matches(request) &&
      (p.getRoute() == null ||
          Strings.equals(p.getRoute().getMethod(),"*") ||
          Strings.equalsIgnoreCase(p.getRoute().getMethod(),request.getMethod()));
}
origin: org.leapframework/leap-oauth2

  @Override
  public void handleRequest(Request request, Response response, OAuth2Params params,
               Consumer<AuthzAccessToken> callback) throws Throwable {
    if(!HTTP.Method.valueOf(request.getMethod()).isPost()){
      handleError(request,response,params,
          getOauth2Error(key -> OAuth2Errors.invalidRequestError(request,key,"this grant_type only accept post method."),INVALID_REQUEST_INVALID_HTTP_METHOD,"POST"));
      return;
    }
    AuthzClientCredentials credentials = new SamplingAuthzClientCredentials(params.getClientId(),params.getClientSecret());

    AuthzClient client = validateClientSecret(request, response,credentials);
    
    if(client == null){
      return;
    }

    callback.accept(tokenManager.createAccessToken(new SimpleAuthzAuthentication(params, client)));
  }
}
origin: org.leapframework/leap-oauth2-server

  @Override
  public void handleRequest(Request request, Response response, OAuth2Params params,
               Consumer<AuthzAccessToken> callback) throws Throwable {
    if(!HTTP.Method.valueOf(request.getMethod()).isPost()){
      handleError(request,response,params,
          getOauth2Error(key -> OAuth2Errors.invalidRequestError(request,key,"this grant_type only accept post method."),INVALID_REQUEST_INVALID_HTTP_METHOD,"POST"));
      return;
    }
    AuthzClientCredentials credentials = new SamplingAuthzClientCredentials(params.getClientId(),params.getClientSecret());

    AuthzClient client = validateClientSecret(request, response,credentials);
    
    if(client == null){
      return;
    }

    callback.accept(tokenManager.createAccessToken(new SimpleAuthzAuthentication(params, client)));
  }
}
leap.webRequestgetMethod

Popular methods of Request

  • getHeader
  • getParameter
  • getAttribute
  • getContextPath
  • getPath
  • getServletRequest
  • setAttribute
  • forwardToView
  • getMessageSource
  • getSession
  • getUri
  • getValidation
  • getUri,
  • getValidation,
  • tryGetCurrent,
  • getCharacterEncoding,
  • getContextUrl,
  • getLocale,
  • getParameters,
  • getQueryString,
  • getUriWithQueryString

Popular in Java

  • Parsing JSON documents to java classes using gson
  • setRequestProperty (URLConnection)
  • startActivity (Activity)
  • getSystemService (Context)
  • Point (java.awt)
    A point representing a location in (x,y) coordinate space, specified in integer precision.
  • HttpURLConnection (java.net)
    An URLConnection for HTTP (RFC 2616 [http://tools.ietf.org/html/rfc2616]) used to send and receive d
  • ByteBuffer (java.nio)
    A buffer for bytes. A byte buffer can be created in either one of the following ways: * #allocate
  • NumberFormat (java.text)
    The abstract base class for all number formats. This class provides the interface for formatting and
  • Enumeration (java.util)
    A legacy iteration interface.New code should use Iterator instead. Iterator replaces the enumeration
  • Modifier (javassist)
    The Modifier class provides static methods and constants to decode class and member access modifiers
  • Best IntelliJ plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now