net.coderazzi.filters.gui
Interface IParserModel

All Known Implementing Classes:
ParserModel

public interface IParserModel

Interface defining the model required to use and create IParser instances.

Author:
Luis M Pena - lu@coderazzi.net

Field Summary
static String COMPARATOR_PROPERTY
          Property fired when any class' comparator changes.
static String FORMAT_PROPERTY
          Property fired when any class' format changes.
static String IGNORE_CASE_PROPERTY
          Property fired when the ignore case value changes.
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener listener)
          Adds a PropertyChangeListener.
Any property change will be transmitted as an event
 IParser createParser(IFilterEditor editor)
          Creates a text parser for the given editor.
 Comparator getComparator(Class c)
          Returns the Comparator for the given class.
It never returns null.
 Format getFormat(Class c)
          Returns the Format for the given class.
 Comparator<String> getStringComparator(boolean ignoreCase)
          Returns the Comparator used for String comparisons.
 boolean isIgnoreCase()
          Returns true if the String comparator ignores case
Note that this is redundant information, which can be retrieved from the getComparator(Class) method with a String.class parameter.
 void removePropertyChangeListener(PropertyChangeListener listener)
          Removes an existing PropertyChangeListener.
 void setComparator(Class c, Comparator format)
          Defines the Comparator for the given class.
 void setFormat(Class c, Format format)
          Defines the Format for the given class.
 void setIgnoreCase(boolean set)
          Sets a String comparator that is case sensitive/insensitive.
 

Field Detail

IGNORE_CASE_PROPERTY

static final String IGNORE_CASE_PROPERTY
Property fired when the ignore case value changes.

See Also:
Constant Field Values

COMPARATOR_PROPERTY

static final String COMPARATOR_PROPERTY
Property fired when any class' comparator changes.

See Also:
Constant Field Values

FORMAT_PROPERTY

static final String FORMAT_PROPERTY
Property fired when any class' format changes.

See Also:
Constant Field Values
Method Detail

createParser

IParser createParser(IFilterEditor editor)
Creates a text parser for the given editor.


getFormat

Format getFormat(Class c)
Returns the Format for the given class.


setFormat

void setFormat(Class c,
               Format format)
Defines the Format for the given class.


getComparator

Comparator getComparator(Class c)
Returns the Comparator for the given class.
It never returns null.


setComparator

void setComparator(Class c,
                   Comparator format)
Defines the Comparator for the given class.


getStringComparator

Comparator<String> getStringComparator(boolean ignoreCase)
Returns the Comparator used for String comparisons.


setIgnoreCase

void setIgnoreCase(boolean set)
Sets a String comparator that is case sensitive/insensitive.


isIgnoreCase

boolean isIgnoreCase()
Returns true if the String comparator ignores case
Note that this is redundant information, which can be retrieved from the getComparator(Class) method with a String.class parameter.


addPropertyChangeListener

void addPropertyChangeListener(PropertyChangeListener listener)
Adds a PropertyChangeListener.
Any property change will be transmitted as an event


removePropertyChangeListener

void removePropertyChangeListener(PropertyChangeListener listener)
Removes an existing PropertyChangeListener.