org.mmbase.storage.search.implementation
Class BasicFieldValueInConstraint

java.lang.Object
  extended by org.mmbase.storage.search.implementation.BasicConstraint
      extended by org.mmbase.storage.search.implementation.BasicFieldConstraint
          extended by org.mmbase.storage.search.implementation.BasicFieldValueInConstraint
All Implemented Interfaces:
Serializable, Constraint, FieldConstraint, FieldValueInConstraint

public class BasicFieldValueInConstraint
extends BasicFieldConstraint
implements FieldValueInConstraint, Serializable

Basic implementation.

Since:
MMBase-1.7
Version:
$Id: BasicFieldValueInConstraint.java 41982 2010-04-20 14:05:14Z michiel $
Author:
Rob van Maris
See Also:
Serialized Form

Field Summary
 
Fields inherited from class org.mmbase.storage.search.implementation.BasicConstraint
modifiable
 
Constructor Summary
BasicFieldValueInConstraint(StepField field)
          Constructor.
 
Method Summary
 BasicFieldValueInConstraint addValue(Object value)
          Adds value.
 boolean equals(Object obj)
          Compares this constraint to the specified object.
 SortedSet<Object> getValues()
          Gets the list of values that is specified for this constraint.
 int hashCode()
           
 String toString()
          Returns a string representation of this FieldValueInConstraint.
 
Methods inherited from class org.mmbase.storage.search.implementation.BasicFieldConstraint
getField, getFieldName, isCaseSensitive, matches, setCaseSensitive
 
Methods inherited from class org.mmbase.storage.search.implementation.BasicConstraint
getBasicSupportLevel, isInverse, setInverse, setUnmodifiable
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface org.mmbase.storage.search.FieldConstraint
getField, isCaseSensitive, matches
 
Methods inherited from interface org.mmbase.storage.search.Constraint
getBasicSupportLevel, isInverse, setUnmodifiable
 

Constructor Detail

BasicFieldValueInConstraint

public BasicFieldValueInConstraint(StepField field)
Constructor.

Parameters:
field - The associated field.
Method Detail

addValue

public BasicFieldValueInConstraint addValue(Object value)
Adds value.

Parameters:
value - The value.
Returns:
This BasicFieldValueInConstraint instance.
Throws:
IllegalArgumentException - when an invalid argument is supplied.
See Also:
FieldValueInConstraint.getValues()

getValues

public SortedSet<Object> getValues()
Description copied from interface: FieldValueInConstraint
Gets the list of values that is specified for this constraint.

Specified by:
getValues in interface FieldValueInConstraint

equals

public boolean equals(Object obj)
Description copied from interface: Constraint
Compares this constraint to the specified object. The result is true if and only if the argument is a non-null Constraint object representing the same constraint(s).

Specified by:
equals in interface Constraint
Overrides:
equals in class BasicFieldConstraint
Parameters:
obj - The object to compare with.
Returns:
true if the objects are equal, false otherwise.

hashCode

public int hashCode()
Specified by:
hashCode in interface Constraint
Overrides:
hashCode in class BasicFieldConstraint

toString

public String toString()
Description copied from interface: FieldValueInConstraint
Returns a string representation of this FieldValueInConstraint. The string representation has the form "FieldValueInConstraint(inverse:<:inverse>, field:<field>, casesensitive:<casesensitive>, values:<values>)" where

Specified by:
toString in interface FieldValueInConstraint
Overrides:
toString in class BasicFieldConstraint
Returns:
A string representation of this FieldValueInConstraint.


MMBase 2.0-SNAPSHOT - null