com.rubecula.jquantity
Class QuantityProperties
java.lang.Object
java.util.Dictionary
java.util.Hashtable
java.util.Properties
com.rubecula.util.ConvenientProperties
com.rubecula.jquantity.QuantityProperties
- All Implemented Interfaces:
- java.lang.Cloneable, Lookupable, java.util.Map, java.io.Serializable
- Direct Known Subclasses:
- Loader
- public class QuantityProperties
- extends ConvenientProperties
- implements Lookupable
Class
to model JQuantities which can be read from a properties file,
stored back and looked up (using a key string) the application.
- Since:
- V_0_4
- Version:
- $Revision: 1.3 $
- Author:
- Robin Hillyard
- See Also:
- Serialized Form
Nested classes inherited from class java.util.Hashtable |
|
Fields inherited from class java.util.Properties |
defaults |
Fields inherited from class java.util.Hashtable |
|
Methods inherited from class java.util.Properties |
getProperty, list, load, propertyNames, save, setProperty, store |
Methods inherited from class java.util.Hashtable |
clear, clone, contains, containsKey, containsValue, elements, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, rehash, remove, size, toString, values |
Methods inherited from class java.lang.Object |
finalize, getClass, notify, notifyAll, wait, wait, wait |
QuantityProperties
public QuantityProperties()
QuantityProperties
public QuantityProperties(java.util.Properties defaults)
- Parameters:
defaults
-
QuantityProperties
public QuantityProperties(java.io.InputStream stream)
throws java.io.IOException
QuantityProperties
public QuantityProperties(java.io.File file)
throws java.io.FileNotFoundException,
java.io.IOException
QuantityProperties
public QuantityProperties(java.lang.String file)
throws java.io.FileNotFoundException,
java.io.IOException
getKeys
public java.util.Collection getKeys()
- Specified by:
getKeys
in interface Lookupable
getValue
public Presentable getValue(java.lang.String name)
throws PresentableException
- Description copied from interface:
Lookupable
- Method to lookup a value by name.
- Specified by:
getValue
in interface Lookupable
- Parameters:
name
- the name or key to be looked up.
- Returns:
- a Presentable value corresponding to the current value of name.
- Throws:
PresentableException
- name not be found.