JIDE 3.5.15

com.jidesoft.filter
Class WildcardFilter<T>

java.lang.Object
  extended by com.jidesoft.filter.AbstractFilter<T>
      extended by com.jidesoft.filter.RegexFilter<T>
          extended by com.jidesoft.filter.WildcardFilter<T>
All Implemented Interfaces:
Filter<T>, ObjectGrouperSupport, Serializable, Cloneable
Direct Known Subclasses:
AutoFilterUtils.TableWildcardFilter

public class WildcardFilter<T>
extends RegexFilter<T>

A filter implements filtering a string based the wildcards. It uses the following three chars as the wildcards.

 
 

See Also:
Serialized Form

Field Summary
 
Fields inherited from class com.jidesoft.filter.RegexFilter
_beginWith, _regex
 
Fields inherited from interface com.jidesoft.filter.Filter
ALL, CUSTOM, NULL, SEPARATOR
 
Constructor Summary
WildcardFilter()
           
WildcardFilter(String pattern)
           
 
Method Summary
protected  String convertFromPatternToRegex(String pattern)
          Converts the wildcards enabled pattern to the pattern used in Java Pattern class.
 boolean equals(Object obj)
           
 boolean isValueFiltered(T value)
          Checks to see if the value should be filtered.
 void setPattern(String pattern)
          Sets the pattern.
 
Methods inherited from class com.jidesoft.filter.RegexFilter
convertElementToString, createRegexPattern, getPattern, getPreference, isBeginWith, isCaseSensitive, isEndWith, setBeginWith, setCaseSensitive, setEndWith, setPreference, stricterThan
 
Methods inherited from class com.jidesoft.filter.AbstractFilter
addFilterListener, clone, fireFilterChanged, fireFilterContentChanged, fireFilterDisabled, fireFilterEnabled, fireFilterNameChanged, getConditionString, getFilterFactory, getFilterFactoryName, getFilterListeners, getName, getObjectGrouper, getObjectGrouperName, isEnabled, isFilterValid, removeFilterListener, setEnabled, setFilterFactory, setFilterFactoryName, setName, setObjectGrouper, setObjectGrouperName
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WildcardFilter

public WildcardFilter()

WildcardFilter

public WildcardFilter(String pattern)
Method Detail

setPattern

public void setPattern(String pattern)
Description copied from class: RegexFilter
Sets the pattern.

Overrides:
setPattern in class RegexFilter<T>
Parameters:
pattern - the new pattern.
See Also:
Pattern

convertFromPatternToRegex

protected String convertFromPatternToRegex(String pattern)
Converts the wildcards enabled pattern to the pattern used in Java Pattern class.

Overrides:
convertFromPatternToRegex in class RegexFilter<T>
Parameters:
pattern - the input pattern.
Returns:
the pattern string used by Pattern.

isValueFiltered

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

Specified by:
isValueFiltered in interface Filter<T>
Overrides:
isValueFiltered in class RegexFilter<T>
Parameters:
value - the value to filter
Returns:
true if the value should be filtered. Otherwise false.

equals

public boolean equals(Object obj)
Overrides:
equals in class RegexFilter<T>

JIDE 3.5.15