WEBsina Software

com.websina.util
Class FileUtil

java.lang.Object
  extended bycom.websina.util.FileUtil

public class FileUtil
extends java.lang.Object

This is utility class to load a file.

Since:
1.0

Constructor Summary
FileUtil(java.io.InputStream is)
           
FileUtil(java.lang.String filename)
           
 
Method Summary
 void read(java.util.List names, java.util.Properties prop)
          The method loads the file (properties file) into a property names List object and a Properties object.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

FileUtil

public FileUtil(java.lang.String filename)
Parameters:
filename - the file name, it must be in the classpath.

FileUtil

public FileUtil(java.io.InputStream is)
Parameters:
is - InputStream to be read.
Method Detail

read

public void read(java.util.List names,
                 java.util.Properties prop)
          throws java.io.IOException
The method loads the file (properties file) into a property names List object and a Properties object. Both objects have to be initialized. This is used when one wants to keep the properties names in order.

Parameters:
names - the properties name list.
prop - the Properties itself.
Throws:
java.io.IOException

WEBsina Software