org.fuin.utils4j.filter
Class StringPropertyFilter

java.lang.Object
  extended by org.fuin.utils4j.filter.PropertyFilter
      extended by org.fuin.utils4j.filter.StringPropertyFilter
All Implemented Interfaces:
Filter

public class StringPropertyFilter
extends PropertyFilter

Defines a filter on a String property.


Constructor Summary
StringPropertyFilter(java.lang.String newPropertyName, StringFilter.Operator newOperator, java.lang.String constValue)
          Constructor with a property and an operator.
StringPropertyFilter(java.lang.String newPropertyName, java.lang.String newOperator, java.lang.String constValue)
          Constructor with a property and an operator name.
 
Method Summary
 boolean complies(java.lang.Object obj)
          Checks if the argument complies with the condition of the filter.
 java.lang.String getConstValue()
          Returns the constant value any value is compared with.
 StringFilter.Operator getOperator()
          Returns the operator for compare operations.
 java.lang.String getOperatorName()
          Returns the operator for compare operations.
 java.lang.String toString()
          
 
Methods inherited from class org.fuin.utils4j.filter.PropertyFilter
getProperty, getPropertyName
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

StringPropertyFilter

public StringPropertyFilter(java.lang.String newPropertyName,
                            StringFilter.Operator newOperator,
                            java.lang.String constValue)
Constructor with a property and an operator.

Parameters:
newPropertyName - Name of the property.
newOperator - Operator to use.
constValue - Value to compare with.

StringPropertyFilter

public StringPropertyFilter(java.lang.String newPropertyName,
                            java.lang.String newOperator,
                            java.lang.String constValue)
Constructor with a property and an operator name.

Parameters:
newPropertyName - Name of the property.
newOperator - Operator to use.
constValue - Value to compare with.
Method Detail

complies

public final boolean complies(java.lang.Object obj)
Checks if the argument complies with the condition of the filter.

Parameters:
obj - Object to be tested for compliance
Returns:
If object complies TRUE else FALSE is returned.

toString

public final java.lang.String toString()

Overrides:
toString in class java.lang.Object

getOperator

public final StringFilter.Operator getOperator()
Returns the operator for compare operations.

Returns:
Operator.

getOperatorName

public final java.lang.String getOperatorName()
Returns the operator for compare operations.

Returns:
Operator.

getConstValue

public final java.lang.String getConstValue()
Returns the constant value any value is compared with.

Returns:
String value.


Copyright © 2009 Future Invent Informationsmanagement GmbH. All Rights Reserved.