jclass
Class ResourceFileReader
java.lang.Object
|
+--jclass.ResourceFileReader
- public class ResourceFileReader
- extends java.lang.Object
This class is obsolete. Please use ResourceHash.fromFile() instead.
A class that reads specific resource files and stores the resources
ito a ResourceHash for later use from inside the calling program.
Should be useful for modifying the constants of the system without
having to recompile.
A resource file looks like this:
# comment line
Resource1 valueofresource1
Resource2 valueofresource2
Resource3 " string value of resource 3 "
The values are treated as simple strings and the overall return should
be a ResourceHash. The resourc hash provides good methods of handling
the resource names. I wanted to separate the reading part from
the real handler (the hash) in order not to overload the system with
a big object.
Written: Radu Sion
Version: 0.19 for 1.1.1 io stuff
Source: ResourceFileReader.java
Visit
Smart Software
- See Also:
ResourceHash
Method Summary |
static ResourceHash |
read(java.lang.String filename)
Reads a resource file and fills a hash with resources read from that file. |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
ResourceFileReader
public ResourceFileReader()
read
public static ResourceHash read(java.lang.String filename)
- Reads a resource file and fills a hash with resources read from that file.
No parameter checkings are performed.
- Parameters:
filename
- Resource file name- Returns:
- A resource hash if ok, null if some error occured