rewrite-config-servlet 2.0.0.Alpha2

org.ocpsoft.rewrite.servlet.config
Class Query

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.Query
All Implemented Interfaces:
Bindable<Query>, Condition, ConditionBuilder, ConfigurationElement

public abstract class Query
extends HttpCondition
implements Bindable<Query>

A Condition that inspects the value of org.ocpsoft.rewrite.servlet.http.event.HttpServletRewrite#getRequestQueryString()

Author:
Lincoln Baxter, III

Field Summary
protected  DefaultBindable<?> bindable
           
 
Constructor Summary
Query()
           
 
Method Summary
 Query bindsTo(Binding binding)
          Bind the values of this Query query to the given Binding.
 List<Binding> getBindings()
           
static Query matches(String queryPattern)
          Return a new Condition matching against the entire HttpServletRequest.getQueryString()
static Query parameterExists(String namePattern)
          Return a new Condition matching against the existence of specific parameters within HttpServletRequest.getQueryString()
static Query valueExists(String valuePattern)
          Return a new Condition matching against the existence of a parameter values within HttpServletRequest.getQueryString()
 
Methods inherited from class org.ocpsoft.rewrite.servlet.config.HttpCondition
evaluate, evaluateHttp
 
Methods inherited from class org.ocpsoft.rewrite.config.DefaultConditionBuilder
and, andNot, create, or, orNot, wrap
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

bindable

protected final DefaultBindable<?> bindable
Constructor Detail

Query

public Query()
Method Detail

bindsTo

public Query bindsTo(Binding binding)
Bind the values of this Query query to the given Binding.

Specified by:
bindsTo in interface Bindable<Query>

getBindings

public List<Binding> getBindings()
Specified by:
getBindings in interface Bindable<Query>

matches

public static Query matches(String queryPattern)
Return a new Condition matching against the entire HttpServletRequest.getQueryString()

This value may be bound using {param} statements.

See also: bindsTo(Binding)


parameterExists

public static Query parameterExists(String namePattern)
Return a new Condition matching against the existence of specific parameters within HttpServletRequest.getQueryString()

The values of all matching parameters may be bound. By default, matching values are bound to the EvaluationContext, and are stored by parameter name.

See also: bindsTo(Binding)


valueExists

public static Query valueExists(String valuePattern)
Return a new Condition matching against the existence of a parameter values within HttpServletRequest.getQueryString()

The values of all matching parameter values may be bound. By default, matching values are bound to the EvaluationContext.

See also: bindsTo(Binding)


rewrite-config-servlet 2.0.0.Alpha2

Copyright © 2012 OCPsoft. All Rights Reserved.