|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectit.geosolutions.tools.io.file.reader.TextReader
public class TextReader
Constructor Summary | |
---|---|
TextReader()
|
Method Summary | |
---|---|
static String |
toString(File file)
Get the contents of a File as a String using the default character encoding. |
static String |
toString(File file,
String encoding)
Get the contents of a File as a String using the specified character encoding. |
static String |
toString(StreamSource src)
Convert the input from the provided Reader into a String . |
static String |
toString(StreamSource src,
String ecoding)
Convert the input from the provided Reader into a String . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public TextReader()
Method Detail |
---|
public static String toString(File file, String encoding)
File
as a String using the specified character encoding.
file
- File
to read fromencoding
- IANA encoding
String
containig the content of the File
or
null if an error happens.
public static String toString(File file)
File
as a String using the default character encoding.
file
- File
to read from
String
containig the content of the File
or
null if an error happens.
public static String toString(StreamSource src, String ecoding) throws IOException
Reader
into a String
.
inputStream
- the Reader
to copy from.
String
that contains the content of the provided Reader
.
IOException
- in case something bad happens.public static String toString(StreamSource src) throws IOException
Reader
into a String
.
inputStream
- the Reader
to copy from.
String
that contains the content of the provided Reader
.
IOException
- in case something bad happens.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |