Tabnine Logo
FacesServlet$HttpMethod.valueOf
Code IndexAdd Tabnine to your IDE (free)

How to use
valueOf
method
in
javax.faces.webapp.FacesServlet$HttpMethod

Best Java code snippets using javax.faces.webapp.FacesServlet$HttpMethod.valueOf (Showing top 20 results out of 315)

origin: javax/javaee-web-api

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: com.sun.faces/jsf-api

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
    
  }
  return result;
}
origin: org.glassfish/javax.faces

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: javax.faces/javax.faces-api

    HttpMethod.valueOf(cur);
    isKnownHttpMethod = true;
  } catch (IllegalArgumentException e) {
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4))
      );
} else if (4 == allowedKnownHttpMethodsStringList.size()) {
  allowedKnownHttpMethods = EnumSet.of(
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0))
      );
origin: jboss/jboss-javaee-specs

    HttpMethod.valueOf(cur);
    isKnownHttpMethod = true;
  } catch (IllegalArgumentException e) {
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4))
      );
} else if (4 == allowedKnownHttpMethodsStringList.size()) {
  allowedKnownHttpMethods = EnumSet.of(
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0))
      );
origin: com.sun.faces/jsf-api

    HttpMethod.valueOf(cur);
    isKnownHttpMethod = true;
  } catch (IllegalArgumentException e) {
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4))
      );
} else if (4 == allowedKnownHttpMethodsStringList.size()) {
  allowedKnownHttpMethods = EnumSet.of(
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0))
      );
origin: javax/javaee-web-api

    HttpMethod.valueOf(cur);
    isKnownHttpMethod = true;
  } catch (IllegalArgumentException e) {
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4))
      );
} else if (4 == allowedKnownHttpMethodsStringList.size()) {
  allowedKnownHttpMethods = EnumSet.of(
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1))
      );
      HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0))
      );
origin: eclipse-ee4j/mojarra

private void initializeAllowedKnownHttpMethods(List<String> allowedKnownHttpMethodsStringList) {
  if (5 == allowedKnownHttpMethodsStringList.size()) {
    allowedKnownHttpMethods = EnumSet.of(
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)));
        EnumSet.of(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)));
      restList.add(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(i)));
    HttpMethod first = HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0));
    HttpMethod[] rest = new HttpMethod[restList.size()];
    restList.toArray(rest);
origin: eclipse-ee4j/mojarra

private void initializeAllowedKnownHttpMethods(List<String> allowedKnownHttpMethodsStringList) {
  if (5 == allowedKnownHttpMethodsStringList.size()) {
    allowedKnownHttpMethods = EnumSet.of(
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)));
        EnumSet.of(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)));
      restList.add(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(i)));
    HttpMethod first = HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0));
    HttpMethod[] rest = new HttpMethod[restList.size()];
    restList.toArray(rest);
origin: org.glassfish/javax.faces

public void initializeAllowedKnownHttpMethods(List<String> allowedKnownHttpMethodsStringList) {
  if (5 == allowedKnownHttpMethodsStringList.size()) {
    allowedKnownHttpMethods = EnumSet.of(
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)));
        EnumSet.of(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)));
      restList.add(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(i)));
    HttpMethod first = HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0));
    HttpMethod[] rest = new HttpMethod[restList.size()];
    restList.toArray(rest);
origin: org.glassfish/jakarta.faces

private void initializeAllowedKnownHttpMethods(List<String> allowedKnownHttpMethodsStringList) {
  if (5 == allowedKnownHttpMethodsStringList.size()) {
    allowedKnownHttpMethods = EnumSet.of(
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(4)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(3)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)), 
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(2)));
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)),
        HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(1)));
        EnumSet.of(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0)));
      restList.add(HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(i)));
    HttpMethod first = HttpMethod.valueOf(allowedKnownHttpMethodsStringList.get(0));
    HttpMethod[] rest = new HttpMethod[restList.size()];
    restList.toArray(rest);
origin: jboss/jboss-javaee-specs

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: eclipse-ee4j/mojarra

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: eclipse-ee4j/mojarra

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: javax.faces/javax.faces-api

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: org.glassfish/jakarta.faces

private boolean isHttpMethodValid(HttpServletRequest request) {
  boolean result = false;
  if (allowAllMethods) {
    result = true;
  } else {
    String requestMethodString = request.getMethod();
    HttpMethod requestMethod = null;
    boolean isKnownHttpMethod;
    try {
      requestMethod = HttpMethod.valueOf(requestMethodString);
      isKnownHttpMethod = true;
    } catch (IllegalArgumentException e) {
      isKnownHttpMethod = false;
    }
    if (isKnownHttpMethod) {
      result = allowedKnownHttpMethods.contains(requestMethod);
    } else {
      result = allowedUnknownHttpMethods.contains(requestMethodString);
    }
  }
  return result;
}
origin: eclipse-ee4j/mojarra

private boolean isKnownHttpMethod(String httpMethod) {
  try {
    HttpMethod.valueOf(httpMethod);
    return true;
  } catch (IllegalArgumentException e) {
    return false;
  }
}

origin: org.glassfish/jakarta.faces

private boolean isKnownHttpMethod(String httpMethod) {
  try {
    HttpMethod.valueOf(httpMethod);
    return true;
  } catch (IllegalArgumentException e) {
    return false;
  }
}

origin: eclipse-ee4j/mojarra

private boolean isKnownHttpMethod(String httpMethod) {
  try {
    HttpMethod.valueOf(httpMethod);
    return true;
  } catch (IllegalArgumentException e) {
    return false;
  }
}

origin: org.glassfish/javax.faces

private boolean isKnownHttpMethod(String httpMethod) {
  try {
    HttpMethod.valueOf(httpMethod);
    return true;
  } catch (IllegalArgumentException e) {
    return false;
  }
}

javax.faces.webappFacesServlet$HttpMethodvalueOf

Popular methods of FacesServlet$HttpMethod

  • ordinal
  • values

Popular in Java

  • Making http requests using okhttp
  • setRequestProperty (URLConnection)
  • getSystemService (Context)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • SQLException (java.sql)
    An exception that indicates a failed JDBC operation. It provides the following information about pro
  • Hashtable (java.util)
    A plug-in replacement for JDK1.5 java.util.Hashtable. This version is based on org.cliffc.high_scale
  • LinkedHashMap (java.util)
    LinkedHashMap is an implementation of Map that guarantees iteration order. All optional operations a
  • Stack (java.util)
    Stack is a Last-In/First-Out(LIFO) data structure which represents a stack of objects. It enables u
  • Collectors (java.util.stream)
  • XPath (javax.xml.xpath)
    XPath provides access to the XPath evaluation environment and expressions. Evaluation of XPath Expr
  • Top 15 Vim Plugins
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

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