org.riotfamily.common.io
Class AbstractTokenFilterReader

java.lang.Object
  extended by java.io.Reader
      extended by java.io.FilterReader
          extended by org.riotfamily.common.io.AbstractTokenFilterReader
All Implemented Interfaces:
Closeable, Readable
Direct Known Subclasses:
MessageFilterReader, PropertyFilterReader

public abstract class AbstractTokenFilterReader
extends FilterReader

Abstract base class for FilterReaders that replace ${placehoder} tokens.

Author:
Felix Gnass [fgnass at neteye dot de]

Field Summary
 
Fields inherited from class java.io.FilterReader
in
 
Fields inherited from class java.io.Reader
lock
 
Constructor Summary
AbstractTokenFilterReader(Reader in)
           
 
Method Summary
protected abstract  String getReplacement(String key)
           
 int read()
           
 int read(char[] cbuf, int off, int len)
           
 
Methods inherited from class java.io.FilterReader
close, mark, markSupported, ready, reset, skip
 
Methods inherited from class java.io.Reader
read, read
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AbstractTokenFilterReader

public AbstractTokenFilterReader(Reader in)
Method Detail

read

public int read()
         throws IOException
Overrides:
read in class FilterReader
Throws:
IOException

read

public final int read(char[] cbuf,
                      int off,
                      int len)
               throws IOException
Overrides:
read in class FilterReader
Throws:
IOException
See Also:
Reader.read(char[], int, int)

getReplacement

protected abstract String getReplacement(String key)