hudson.util
Class TextFile
java.lang.Object
hudson.util.TextFile
public class TextFile
- extends Object
Represents a text file.
Provides convenience methods for reading and writing to it.
- Author:
- Kohsuke Kawaguchi
file
public final File file
TextFile
public TextFile(File file)
exists
public boolean exists()
delete
public void delete()
read
public String read()
throws IOException
- Reads the entire contents and returns it.
- Throws:
IOException
write
public void write(String text)
throws IOException
- Overwrites the file by the given string.
- Throws:
IOException
readTrim
public String readTrim()
throws IOException
- Throws:
IOException
toString
public String toString()
- Overrides:
toString
in class Object
Copyright © 2004-2013. All Rights Reserved.