|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||
java.lang.Objectorg.globus.cog.util.TextFileLoader
Loads a text file from a resource or file loadFromResource() tries to portably load from both if one fails
| Constructor Summary | |
TextFileLoader()
|
|
| Method Summary | |
boolean |
exists(String resName)
|
String |
loadFromFile(String fileName)
Loads text from a file |
String |
loadFromResource(String resName)
Reads text from a resource |
String |
loadFromStream(InputStream is)
Reads text from an imput stream |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
public TextFileLoader()
| Method Detail |
public String loadFromFile(String fileName)
throws IOException
fileName - the file name to be loaded
IOException
public String loadFromStream(InputStream is)
throws IOException
is - the input stream to read the text from
IOExceptionpublic String loadFromResource(String resName)
resName - the name of the resource
public boolean exists(String resName)
|
|||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||||