org.neodatis.odb.impl.core.query.criteria
Class CollectionSizeCriterion

java.lang.Object
  extended by org.neodatis.odb.core.query.criteria.AbstractCriterion
      extended by org.neodatis.odb.impl.core.query.criteria.CollectionSizeCriterion
All Implemented Interfaces:
java.io.Serializable, ICriterion

public class CollectionSizeCriterion
extends AbstractCriterion

A criterio to test collection or array size

Author:
olivier s
See Also:
Serialized Form

Field Summary
static int SIZE_EQ
           
static int SIZE_GE
           
static int SIZE_GT
           
static int SIZE_LE
           
static int SIZE_LT
           
static int SIZE_NE
           
 
Fields inherited from class org.neodatis.odb.core.query.criteria.AbstractCriterion
attributeName
 
Constructor Summary
CollectionSizeCriterion(java.lang.String attributeName, int size, int sizeType)
           
 
Method Summary
 AttributeValuesMap getValues()
           
 boolean match(java.lang.Object valueToMatch)
          To check if an object matches this criterion
 void ready()
          a method to explicitly indicate that the criteria is ready.
 
Methods inherited from class org.neodatis.odb.core.query.criteria.AbstractCriterion
and, canUseIndex, getAllInvolvedFields, getAttributeName, getQuery, match, match, not, or, setAttributeName, setQuery
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

SIZE_EQ

public static final int SIZE_EQ
See Also:
Constant Field Values

SIZE_NE

public static final int SIZE_NE
See Also:
Constant Field Values

SIZE_GT

public static final int SIZE_GT
See Also:
Constant Field Values

SIZE_GE

public static final int SIZE_GE
See Also:
Constant Field Values

SIZE_LT

public static final int SIZE_LT
See Also:
Constant Field Values

SIZE_LE

public static final int SIZE_LE
See Also:
Constant Field Values
Constructor Detail

CollectionSizeCriterion

public CollectionSizeCriterion(java.lang.String attributeName,
                               int size,
                               int sizeType)
Method Detail

match

public boolean match(java.lang.Object valueToMatch)
Description copied from interface: ICriterion
To check if an object matches this criterion

Specified by:
match in interface ICriterion
Specified by:
match in class AbstractCriterion
Returns:
true if object matches the criteria TODO create a math(AttributeValuesMap)

getValues

public AttributeValuesMap getValues()

ready

public void ready()
Description copied from interface: ICriterion
a method to explicitly indicate that the criteria is ready.