ProgramixGenericLib v5.0.1

com.programix.gui.text
Class FilterChainDocument.BasicFilter

java.lang.Object
  extended by com.programix.gui.text.FilterChainDocument.BasicFilter
All Implemented Interfaces:
FilterChainDocument.Filter
Direct Known Subclasses:
FilterChainDocument.WinnowFilter
Enclosing class:
FilterChainDocument

public abstract static class FilterChainDocument.BasicFilter
extends Object
implements FilterChainDocument.Filter

Implements the FilterChainDocument.Filter interface and provides a new, single filter(String) abstract method for subclasses to implement.

Author:
Paul Hyde

Constructor Summary
FilterChainDocument.BasicFilter()
           
 
Method Summary
 String filter(int offset, String src, Document doc)
          Calls the filter(String) method ignoring the offset and the doc.
protected abstract  String filter(String src)
          Implement in subclasses for filters that don't need access to the Document or the offset into the document for the current String insertion.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FilterChainDocument.BasicFilter

public FilterChainDocument.BasicFilter()
Method Detail

filter

public String filter(int offset,
                     String src,
                     Document doc)
Calls the filter(String) method ignoring the offset and the doc.

Specified by:
filter in interface FilterChainDocument.Filter

filter

protected abstract String filter(String src)
Implement in subclasses for filters that don't need access to the Document or the offset into the document for the current String insertion.

Parameters:
src - proposed characters to insert
Returns:
the subset of the proposed characters to insert. If no alterations are needed, the src may be returned.

ProgramixGenericLib v5.0.1

Copyright © 2001-2009 Programix Incorporated. All rights reserved. ProgramixGenericLib is free and is OSI Certified Open Source Software under the BSD license.