com.vaadin.addon.jpacontainer.filter
Class Filters

java.lang.Object
  extended by com.vaadin.addon.jpacontainer.filter.Filters

public final class Filters
extends Object

Utility class for creating filter instances.

Since:
1.0
Author:
Petter Holmström (Vaadin Ltd)

Method Summary
static com.vaadin.data.util.filter.And and(com.vaadin.data.Container.Filter... filters)
          Creates a filter that groups filters together in a single conjunction.
static com.vaadin.data.util.filter.And and(List<com.vaadin.data.Container.Filter> filters)
          Creates a filter that groups filters together in a single conjunction.
static com.vaadin.data.Container.Filter between(Object propertyId, Comparable<?> startingPoint, Comparable<?> endingPoint)
          Creates a new filter that accepts all items whose value of propertyId is between startingPoint and endingPoint.
static com.vaadin.data.Container.Filter between(Object propertyId, Object startingPoint, Object endingPoint, boolean includeStartingPoint, boolean includeEndingPoint)
           
static com.vaadin.data.Container.Filter betweenExlusive(Object propertyId, Object startingPoint, Object endingPoint)
          Creates a new filter that accepts all items whose value of propertyId is between startingPoint (exclusive) and endingPoint (exclusive).
static com.vaadin.data.Container.Filter betweenInclusive(Object propertyId, Object startingPoint, Object endingPoint)
          Creates a new filter that accepts all items whose value of propertyId is between startingPoint (inclusive) and endingPoint (inclusive).
static com.vaadin.data.Container.Filter eq(Object propertyId, Object value)
          Creates a new filter that accepts all items whose value of propertyId is equal to value.
static com.vaadin.data.Container.Filter eq(Object propertyId, String value, boolean caseSensitive)
          Creates a new filter that accepts all items whose value of propertyId is equal to value.
static com.vaadin.data.Container.Filter gt(Object propertyId, Object value)
          Creates a new filter that accepts all items whose value of propertyId is greater than value.
static com.vaadin.data.Container.Filter gteq(Object propertyId, Object value)
          Creates a new filter that accepts all items whose value of propertyId is greater than or equal to value.
static com.vaadin.data.Container.Filter isEmpty(Object propertyId)
          Creates a new filter that accepts all items whose value of propertyId is empty.
static com.vaadin.data.Container.Filter isNotEmpty(Object propertyId)
          Creates a new filter that accepts all items whose value of propertyId is not empty.
static com.vaadin.data.Container.Filter isNotNull(Object propertyId)
          Creates a new filter that accepts all items whose value of propertyId is not null.
static com.vaadin.data.Container.Filter isNull(Object propertyId)
          Creates a new filter that accepts all items whose value of propertyId is null.
static JoinFilter joinFilter(String joinProperty, com.vaadin.data.Container.Filter... filters)
          Creates a filter that applies filters (as a conjunction) to the joined property joinProperty.
static com.vaadin.data.Container.Filter like(Object propertyId, String value, boolean caseSensitive)
          Creates a new filter that accepts all items whose value of propertyId matches value.
static com.vaadin.data.Container.Filter lt(Object propertyId, Object value)
          Creates a new filter that accepts all items whose value of propertyId is less than value.
static com.vaadin.data.Container.Filter lteq(Object propertyId, Object value)
          Creates a new filter that accepts all items whose value of propertyId is less than or equal to value.
static com.vaadin.data.Container.Filter not(com.vaadin.data.Container.Filter filter)
          Creates a filter that negates filter.
static com.vaadin.data.util.filter.Or or(com.vaadin.data.Container.Filter... filters)
          Creates a filter that groups filters together in a single disjunction.
static com.vaadin.data.util.filter.Or or(List<com.vaadin.data.Container.Filter> filters)
          Creates a filter that groups filters together in a single disjunction.
static com.vaadin.data.Container.Filter outside(Object propertyId, Object startingPoint, Object endingPoint, boolean includeStartingPoint, boolean includeEndingPoint)
          Creates a new filter that accepts all items whose value of propertyId is outside startingPoint and endingPoint.
static com.vaadin.data.Container.Filter outsideExclusive(Object propertyId, Object startingPoint, Object endingPoint)
          Creates a new filter that accepts all items whose value of propertyId is outside startingPoint (exclusive) and endingPoint (exclusive).
static com.vaadin.data.Container.Filter outsideInclusive(Object propertyId, Object startingPoint, Object endingPoint)
          Creates a new filter that accepts all items whose value of propertyId is outside startingPoint (inclusive) and endingPoint (inclusive).
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

isNull

public static com.vaadin.data.Container.Filter isNull(Object propertyId)
Creates a new filter that accepts all items whose value of propertyId is null.


isNotNull

public static com.vaadin.data.Container.Filter isNotNull(Object propertyId)
Creates a new filter that accepts all items whose value of propertyId is not null.


isEmpty

public static com.vaadin.data.Container.Filter isEmpty(Object propertyId)
Creates a new filter that accepts all items whose value of propertyId is empty.


isNotEmpty

public static com.vaadin.data.Container.Filter isNotEmpty(Object propertyId)
Creates a new filter that accepts all items whose value of propertyId is not empty.


eq

public static com.vaadin.data.Container.Filter eq(Object propertyId,
                                                  String value,
                                                  boolean caseSensitive)
Creates a new filter that accepts all items whose value of propertyId is equal to value.


like

public static com.vaadin.data.Container.Filter like(Object propertyId,
                                                    String value,
                                                    boolean caseSensitive)
Creates a new filter that accepts all items whose value of propertyId matches value. The precent-sign (%) may be used as wildcard.


eq

public static com.vaadin.data.Container.Filter eq(Object propertyId,
                                                  Object value)
Creates a new filter that accepts all items whose value of propertyId is equal to value.


gteq

public static com.vaadin.data.Container.Filter gteq(Object propertyId,
                                                    Object value)
Creates a new filter that accepts all items whose value of propertyId is greater than or equal to value.


gt

public static com.vaadin.data.Container.Filter gt(Object propertyId,
                                                  Object value)
Creates a new filter that accepts all items whose value of propertyId is greater than value.


lteq

public static com.vaadin.data.Container.Filter lteq(Object propertyId,
                                                    Object value)
Creates a new filter that accepts all items whose value of propertyId is less than or equal to value.


lt

public static com.vaadin.data.Container.Filter lt(Object propertyId,
                                                  Object value)
Creates a new filter that accepts all items whose value of propertyId is less than value.


between

public static com.vaadin.data.Container.Filter between(Object propertyId,
                                                       Comparable<?> startingPoint,
                                                       Comparable<?> endingPoint)
Creates a new filter that accepts all items whose value of propertyId is between startingPoint and endingPoint.


between

public static com.vaadin.data.Container.Filter between(Object propertyId,
                                                       Object startingPoint,
                                                       Object endingPoint,
                                                       boolean includeStartingPoint,
                                                       boolean includeEndingPoint)

betweenInclusive

public static com.vaadin.data.Container.Filter betweenInclusive(Object propertyId,
                                                                Object startingPoint,
                                                                Object endingPoint)
Creates a new filter that accepts all items whose value of propertyId is between startingPoint (inclusive) and endingPoint (inclusive).


betweenExlusive

public static com.vaadin.data.Container.Filter betweenExlusive(Object propertyId,
                                                               Object startingPoint,
                                                               Object endingPoint)
Creates a new filter that accepts all items whose value of propertyId is between startingPoint (exclusive) and endingPoint (exclusive).


outside

public static com.vaadin.data.Container.Filter outside(Object propertyId,
                                                       Object startingPoint,
                                                       Object endingPoint,
                                                       boolean includeStartingPoint,
                                                       boolean includeEndingPoint)
Creates a new filter that accepts all items whose value of propertyId is outside startingPoint and endingPoint.


outsideInclusive

public static com.vaadin.data.Container.Filter outsideInclusive(Object propertyId,
                                                                Object startingPoint,
                                                                Object endingPoint)
Creates a new filter that accepts all items whose value of propertyId is outside startingPoint (inclusive) and endingPoint (inclusive).


outsideExclusive

public static com.vaadin.data.Container.Filter outsideExclusive(Object propertyId,
                                                                Object startingPoint,
                                                                Object endingPoint)
Creates a new filter that accepts all items whose value of propertyId is outside startingPoint (exclusive) and endingPoint (exclusive).


not

public static com.vaadin.data.Container.Filter not(com.vaadin.data.Container.Filter filter)
Creates a filter that negates filter.


and

public static com.vaadin.data.util.filter.And and(com.vaadin.data.Container.Filter... filters)
Creates a filter that groups filters together in a single conjunction.


and

public static com.vaadin.data.util.filter.And and(List<com.vaadin.data.Container.Filter> filters)
Creates a filter that groups filters together in a single conjunction.


or

public static com.vaadin.data.util.filter.Or or(com.vaadin.data.Container.Filter... filters)
Creates a filter that groups filters together in a single disjunction.


or

public static com.vaadin.data.util.filter.Or or(List<com.vaadin.data.Container.Filter> filters)
Creates a filter that groups filters together in a single disjunction.


joinFilter

public static JoinFilter joinFilter(String joinProperty,
                                    com.vaadin.data.Container.Filter... filters)
Creates a filter that applies filters (as a conjunction) to the joined property joinProperty. This is only needed for Hibernate, as EclipseLink implicitly joins on nested properties.



Copyright © 2013 Vaadin Ltd. All rights reserved.