com.ibm.di.store
Class PropertyStore

java.lang.Object
  extended by com.ibm.di.store.PropertyStore

public class PropertyStore
extends Object


Field Summary
static String TABLE_PREFIX
           
 
Constructor Summary
PropertyStore(String identifier)
          Initializes this object with a connection to the property store table named name.
 
Method Summary
 void closeStore()
          Closes all resources open by this object.
 Object getProperty(String key)
          Returns a value in the property store.
 List keys()
          Returns an Enumeration of the keys in the store.
 Object removeProperty(String key)
          Removes a value in the property store.
 Object setProperty(String key, Object obj)
          Adds or updates a value in the property store.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

TABLE_PREFIX

public static final String TABLE_PREFIX
See Also:
Constant Field Values
Constructor Detail

PropertyStore

public PropertyStore(String identifier)
              throws Exception
Initializes this object with a connection to the property store table named name.

Parameters:
identifier - The table name
Throws:
Exception
Method Detail

closeStore

public void closeStore()
                throws Exception
Closes all resources open by this object.

Throws:
Exception

setProperty

public Object setProperty(String key,
                          Object obj)
                   throws Exception
Adds or updates a value in the property store. If an update is performed the old value is returned.

Parameters:
key - The unique identifier
obj - The value
Returns:
The old value in case of an update
Throws:
Exception

getProperty

public Object getProperty(String key)
                   throws Exception
Returns a value in the property store.

Parameters:
key - The unique identifier
Returns:
Value in the store or NULL if not found.
Throws:
Exception

removeProperty

public Object removeProperty(String key)
                      throws Exception
Removes a value in the property store.

Parameters:
key - The unique identifier to remove.
Returns:
The old value or NULL if key were not in the table
Throws:
Exception

keys

public List keys()
          throws Exception
Returns an Enumeration of the keys in the store.

Throws:
Exception