java.lang.Object | +--com.ibm.commerce.registry.AbstractManagedDynamicCacheRegistry | +--com.ibm.commerce.registry.TradingAgreementRegistry
TradingAgreementRegistry is where the trading agreements are cached.
Field Summary | |
---|---|
protected
static
TradingAgreementRegistry |
singleton A pointer to the trading agreement registry |
Fields inherited from class com.ibm.commerce.registry. AbstractManagedDynamicCacheRegistry |
COPYRIGHT |
Constructor Summary | |
---|---|
TradingAgreementRegistry() TradingAgreementRegistry constructor. |
Method Summary | |
---|---|
void |
addElement(
TradingAgreementAccessBean tradingAgreement) Add a TradingAgreement to the list. |
java.lang.Object |
createKey(java.lang.String strKey) Creates a cache key |
java.lang.String |
createKeyString(
TypedProperty prop) Creates a cache key |
TradingAgreementAccessBean |
find(java.lang.String key) Returns the TradingAgreementAccessBean with a given id from the cache. |
TradingAgreementAccessBean[] |
findAll(java.lang.String[] taIdStr) Returns all the TradingAgreementAccessBean with the given ids from the cache |
TradingAgreementAccessBean[] |
getAll() Returns all the TradingAgreementAccessBean in the cache |
void |
initialize() Initializes the TradingAgreementRegistry. |
void |
populate(
LRUDynamicHashtable aCache) Populates the cache. |
void |
putAll(
TradingAgreementAccessBean[] ta) This method will store the give TradingAgreementAccessBean in the registry |
void |
refresh() This method refresh the trading agreement registry from the database. |
void |
refreshDependentRegistry(java.lang.String astrRegistryName) Refreshes a dependent registry. |
java.lang.Object |
retrieve(java.lang.Object key) Retrieves an TradingAgreementAccessBean from the database. |
static
TradingAgreementRegistry |
singleton() This method returns a singleton object of the trading agreement registry. |
void |
update(java.lang.String action, java.lang.Object key) Updates a given trading agreement element. |
void |
updateDependentRegistry(java.lang.String astrRegistryName,
java.lang.String astrAction, java.lang.Object aKey) Updates a dependent registry. |
Methods inherited from class com.ibm.commerce.registry. AbstractManagedDynamicCacheRegistry |
addElement,
findObject,
getCache,
getCacheSize,
getElement,
getElementCount,
getElements,
getEvictions,
getHits,
getKeys,
getMisses,
getUsedCacheSize,
removeAllElements,
removeElement,
setCache,
setCacheSize,
setInitialCapacity,
setLoadFactor |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll,
toString, wait, wait, wait |
Field Detail |
---|
protected static TradingAgreementRegistry singleton
Constructor Detail |
---|
public TradingAgreementRegistry()
Method Detail |
---|
public void addElement(TradingAgreementAccessBean tradingAgreement)
tradingAgreement
- the TradingAgreementAccessBean to be added
to the listpublic TradingAgreementAccessBean find(java.lang.String key) throws java.lang.Exception
key
- The trading agreement identifierjava.lang.Exception
public TradingAgreementAccessBean[] findAll(java.lang.String[] taIdStr) throws java.lang.Exception
taIdStr
- The list of trading agreement identifiersjava.lang.Exception
public TradingAgreementAccessBean[] getAll()
public void initialize() throws java.lang.Exception
initialize
in interface
Registry
initialize
in class
AbstractManagedDynamicCacheRegistry
java.lang.Exception
public void putAll(TradingAgreementAccessBean[] ta)
ta
- An array of trading agreement access
beanspublic void updateDependentRegistry(java.lang.String astrRegistryName, java.lang.String astrAction, java.lang.Object aKey)
astrRegistryName
- the registry name.astrAction
- the action.aKey
- the key.java.lang.Exception
public void refreshDependentRegistry(java.lang.String astrRegistryName)
astrRegistryName
- the registry name.java.lang.Exception
public void refresh() throws java.lang.Exception
refresh
in interface
Registry
refresh
in class
AbstractManagedDynamicCacheRegistry
java.lang.Exception
public static TradingAgreementRegistry singleton()
public void update(java.lang.String action, java.lang.Object key) throws java.lang.Exception
update
in interface
ElementUpdate
update
in class
AbstractManagedDynamicCacheRegistry
action
- The valid actions are 'add', 'delete'
and 'update'key
- The key that identifies a particular elementjava.lang.Exception
public java.lang.Object retrieve(java.lang.Object key) throws java.lang.Exception
retrieve
in class
AbstractManagedDynamicCacheRegistry
key
- The key used to locate the object from the databasejava.lang.Exception
public void populate(LRUDynamicHashtable aCache) throws java.lang.Exception
populate
in class
AbstractManagedDynamicCacheRegistry
aCache
- The hashtable table to be populatedjava.lang.Exception
public java.lang.String createKeyString(TypedProperty prop) throws java.lang.Exception
createKeyString
in interface
ElementUpdate
createKeyString
in class
AbstractManagedDynamicCacheRegistry
prop
- The input propertiesjava.lang.Exception
public java.lang.Object createKey(java.lang.String strKey) throws java.lang.Exception
createKey
in interface
ElementUpdate
createKey
in class
AbstractManagedDynamicCacheRegistry
strKey
- The string representation of the cache key.java.lang.Exception