de.intarsys.tools.reader
Class UnEscapeReader
java.lang.Object
java.io.Reader
java.io.FilterReader
de.intarsys.tools.reader.UnEscapeReader
- All Implemented Interfaces:
- IUnEscaper, Closeable, Readable
public class UnEscapeReader
- extends FilterReader
- implements IUnEscaper
A reader that can unescape character data from a wrapped reader.
DefaultEscape
public static final char DefaultEscape
- See Also:
- Constant Field Values
UnEscapeReader
public UnEscapeReader(Reader in)
UnEscapeReader
public UnEscapeReader(Reader in,
char escape,
Map map)
UnEscapeReader
public UnEscapeReader(Reader in,
Map map)
unescape
public static String unescape(String in)
throws IOException
- Throws:
IOException
addEscapedCharacter
public void addEscapedCharacter(char key,
char value)
- Specified by:
addEscapedCharacter
in interface IUnEscaper
close
public void close()
throws IOException
- Specified by:
close
in interface Closeable
- Overrides:
close
in class FilterReader
- Throws:
IOException
getEscape
public char getEscape()
getEscapeMap
public Map getEscapeMap()
getUnicodePrefix
public char getUnicodePrefix()
isMapped
public boolean isMapped()
- Specified by:
isMapped
in interface IUnEscaper
read
public int read()
throws IOException
- Overrides:
read
in class FilterReader
- Throws:
IOException
read
public int read(char[] cbuf,
int off,
int len)
throws IOException
- Overrides:
read
in class FilterReader
- Throws:
IOException
removeEscapedCharacter
public void removeEscapedCharacter(char key)
removeEscapedCharacters
public void removeEscapedCharacters()
setEscape
public void setEscape(char newEscape)
- Specified by:
setEscape
in interface IUnEscaper
setUnicodePrefix
public void setUnicodePrefix(char newUniChar)
skip
public long skip(long n)
throws IOException
- Overrides:
skip
in class FilterReader
- Throws:
IOException
Copyright © 2008 intarsys consulting GmbH. All Rights Reserved.