net.server.servlets
Class FileUtil

java.lang.Object
  extended by net.server.servlets.FileUtil

public class FileUtil
extends java.lang.Object

File Utility Class


Method Summary
static void close(java.io.BufferedReader br)
          Closes the BufferedReader
static void close(java.io.BufferedWriter bw)
          Closes the BufferedWriter
static java.io.File getFile(java.lang.String f)
          Returns an instance of a File
static java.io.FileInputStream getFileInputStream(java.lang.String f)
          Returns an instance of a FileInputStream
static java.util.Properties loadProperties(java.lang.String f)
          Returns an instance of a Property
static java.io.BufferedReader openInputFile(java.io.File f)
          Returns an instance of a BufferedReader
static java.io.BufferedWriter openOutputFile(java.io.File f)
          Returns an instance of a BufferedWriter
static void println(java.io.BufferedWriter bw, java.lang.Object o)
          println() Method Appends the object to the BufferedWriter
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getFile

public static java.io.File getFile(java.lang.String f)
Returns an instance of a File

Returns:
File

loadProperties

public static java.util.Properties loadProperties(java.lang.String f)
                                           throws net.server.servlets.PropFileException
Returns an instance of a Property

Returns:
Properties
Throws:
net.server.servlets.PropFileException

getFileInputStream

public static java.io.FileInputStream getFileInputStream(java.lang.String f)
                                                  throws java.io.FileNotFoundException,
                                                         java.io.IOException
Returns an instance of a FileInputStream

Returns:
FileInputStream
Throws:
java.io.FileNotFoundException
java.io.IOException

openInputFile

public static java.io.BufferedReader openInputFile(java.io.File f)
                                            throws java.io.FileNotFoundException,
                                                   java.io.IOException
Returns an instance of a BufferedReader

Returns:
BufferedReader
Throws:
java.io.FileNotFoundException
java.io.IOException

openOutputFile

public static java.io.BufferedWriter openOutputFile(java.io.File f)
                                             throws java.io.FileNotFoundException,
                                                    java.io.IOException
Returns an instance of a BufferedWriter

Returns:
BufferedWriter
Throws:
java.io.FileNotFoundException
java.io.IOException

close

public static void close(java.io.BufferedReader br)
Closes the BufferedReader


close

public static void close(java.io.BufferedWriter bw)
Closes the BufferedWriter


println

public static void println(java.io.BufferedWriter bw,
                           java.lang.Object o)
println() Method Appends the object to the BufferedWriter