JIDE 3.5.15

com.jidesoft.filter
Class NotFilter

java.lang.Object
  extended by com.jidesoft.filter.AbstractFilter
      extended by com.jidesoft.filter.NotFilter
All Implemented Interfaces:
Filter, ObjectGrouperSupport, Serializable, Cloneable

public class NotFilter
extends AbstractFilter

This filter will return the opposite value from isValueFiltered(Object) method from the filter it contains. In the other word, it is a NOT logic.

See Also:
Serialized Form

Field Summary
 
Fields inherited from interface com.jidesoft.filter.Filter
ALL, CUSTOM, NULL, SEPARATOR
 
Constructor Summary
NotFilter(Filter filter)
           
 
Method Summary
 Object clone()
          Creates and returns a copy of the filter.
 boolean equals(Object obj)
           
 Filter getFilter()
           
 boolean isFilterValid()
          Checks if the filter is valid or not.
 boolean isValueFiltered(Object value)
          Checks to see if the value should be filtered.
 void setFilter(Filter filter)
           
 boolean stricterThan(Filter inputFilter)
          Check if this filter is stricter than the input filter while the two filters are with the same class.
 
Methods inherited from class com.jidesoft.filter.AbstractFilter
addFilterListener, fireFilterChanged, fireFilterContentChanged, fireFilterDisabled, fireFilterEnabled, fireFilterNameChanged, getConditionString, getFilterFactory, getFilterFactoryName, getFilterListeners, getName, getObjectGrouper, getObjectGrouperName, getPreference, isEnabled, removeFilterListener, setEnabled, setFilterFactory, setFilterFactoryName, setName, setObjectGrouper, setObjectGrouperName, setPreference
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

NotFilter

public NotFilter(Filter filter)
Method Detail

isValueFiltered

public boolean isValueFiltered(Object value)
Description copied from interface: Filter
Checks to see if the value should be filtered.

Parameters:
value - the value to filter
Returns:
true if the value should be filtered. Otherwise false.

getFilter

public Filter getFilter()

setFilter

public void setFilter(Filter filter)

stricterThan

public boolean stricterThan(Filter inputFilter)
Check if this filter is stricter than the input filter while the two filters are with the same class.

Specified by:
stricterThan in interface Filter
Overrides:
stricterThan in class AbstractFilter
Parameters:
inputFilter - the input filter
Returns:
true if the filter in input filter stricter than the filter in this filter. Otherwise false.

clone

public Object clone()
             throws CloneNotSupportedException
Description copied from class: AbstractFilter
Creates and returns a copy of the filter.

Specified by:
clone in interface Filter
Overrides:
clone in class AbstractFilter
Returns:
a cloned copy of the filter.
Throws:
CloneNotSupportedException - if the cloning of the filter is not supported.

equals

public boolean equals(Object obj)
Overrides:
equals in class Object

isFilterValid

public boolean isFilterValid()
Description copied from class: AbstractFilter
Checks if the filter is valid or not. By default, it just returns true simply. This method will help determine if the filter loaded from a string by invoking AbstractFilter.setPreference(String, Class, com.jidesoft.converter.ConverterContext) is valid or not.

Overrides:
isFilterValid in class AbstractFilter
Returns:
true by default.

JIDE 3.5.15