rewrite-config-servlet 2.0.0.Beta3

org.ocpsoft.rewrite.servlet.config
Class Method

java.lang.Object
  extended by org.ocpsoft.rewrite.config.DefaultConditionBuilder
      extended by org.ocpsoft.rewrite.servlet.config.HttpCondition
          extended by org.ocpsoft.rewrite.servlet.config.Method
All Implemented Interfaces:
Condition, ConditionBuilder

public class Method
extends HttpCondition

A Condition responsible for asserting on the HttpServletRequest.getMethod() property.

Author:
Lincoln Baxter, III

Method Summary
 boolean evaluateHttp(HttpServletRewrite event, EvaluationContext context)
           
static Method isDelete()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is DELETE
static Method isGet()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is GET
static Method isHead()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is HEAD
static Method isOptions()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is OPTIONS
static Method isPost()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is POST
static Method isPut()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is PUT
static Method isTrace()
          Create a Method condition that ensures the current HttpServletRequest.getMethod() is TRACE
 
Methods inherited from class org.ocpsoft.rewrite.servlet.config.HttpCondition
evaluate
 
Methods inherited from class org.ocpsoft.rewrite.config.DefaultConditionBuilder
and, andNot, or, orNot
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isGet

public static Method isGet()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is GET


isPost

public static Method isPost()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is POST


isHead

public static Method isHead()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is HEAD


isOptions

public static Method isOptions()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is OPTIONS


isPut

public static Method isPut()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is PUT


isDelete

public static Method isDelete()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is DELETE


isTrace

public static Method isTrace()
Create a Method condition that ensures the current HttpServletRequest.getMethod() is TRACE


evaluateHttp

public boolean evaluateHttp(HttpServletRewrite event,
                            EvaluationContext context)
Specified by:
evaluateHttp in class HttpCondition

rewrite-config-servlet 2.0.0.Beta3

Copyright © 2013 OCPsoft. All Rights Reserved.