org.mmbase.util.transformers
Class ReaderTransformer

java.lang.Object
  extended byorg.mmbase.util.transformers.ReaderTransformer
All Implemented Interfaces:
CharTransformer, Serializable, Transformer
Direct Known Subclasses:
ByteCharTransformer, ChainedCharTransformer, ConfigurableReaderTransformer, CopyCharTransformer, Identifier, LowerCaser, Rot13, Rot5, Sitestat, SpaceReducer, SpaceRemover, SpaceSwallower, SubstringFactory.Substring, Swallower, TabToSpacesTransformer, Trimmer, UnicodeEscaper, UpperCaser, XmlEntities

public abstract class ReaderTransformer
extends Object
implements CharTransformer

You need only to implement transform(Reader, Writer) you have the simplest kind of tranformer (which is 'streamable'). The name becoming your class name.

Since:
MMBase-1.7
Author:
Michiel Meeuwissen
See Also:
Serialized Form

Constructor Summary
ReaderTransformer()
           
 
Method Summary
 Writer transform(Reader r)
           
abstract  Writer transform(Reader r, Writer w)
           
 String transform(String r)
           
 Writer transformBack(Reader r)
           
 Writer transformBack(Reader r, Writer w)
           
 String transformBack(String r)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.mmbase.util.transformers.Transformer
toString
 

Constructor Detail

ReaderTransformer

public ReaderTransformer()
Method Detail

transform

public abstract Writer transform(Reader r,
                                 Writer w)
Specified by:
transform in interface CharTransformer

transformBack

public Writer transformBack(Reader r,
                            Writer w)
Specified by:
transformBack in interface CharTransformer

transformBack

public final Writer transformBack(Reader r)
Specified by:
transformBack in interface CharTransformer

transform

public final Writer transform(Reader r)
Specified by:
transform in interface CharTransformer

transform

public String transform(String r)
Specified by:
transform in interface CharTransformer

transformBack

public String transformBack(String r)
Specified by:
transformBack in interface CharTransformer


MMBase build 1.8.1.20060716