de.cesr.lara.components.container.memory.impl
Class LDefaultLimitedCapacityBOMemory<BOType extends LaraBehaviouralOption<?,? extends BOType>>

java.lang.Object
  extended by de.cesr.lara.components.container.memory.impl.LDefaultMemory<PropertyType>
      extended by de.cesr.lara.components.container.memory.impl.LDefaultLimitedCapacityMemory<BOType>
          extended by de.cesr.lara.components.container.memory.impl.LDefaultLimitedCapacityBOMemory<BOType>
Type Parameters:
BOType - the type of behavioural options this memory may store
All Implemented Interfaces:
LaraCapacityManageableContainer<BOType>, LaraContainer<BOType>, LaraBOMemory<BOType>, LaraMemory<BOType>, LaraStorageListener, Iterable<BOType>

public class LDefaultLimitedCapacityBOMemory<BOType extends LaraBehaviouralOption<?,? extends BOType>>
extends LDefaultLimitedCapacityMemory<BOType>
implements LaraBOMemory<BOType>


Nested Class Summary
 
Nested classes/interfaces inherited from interface de.cesr.lara.components.container.storage.LaraStorageListener
LaraStorageListener.StorageEvent
 
Field Summary
 
Fields inherited from class de.cesr.lara.components.container.memory.impl.LDefaultLimitedCapacityMemory
DEFAULT_INITIAL_CAPACITY
 
Fields inherited from interface de.cesr.lara.components.container.memory.LaraMemory
UNLIMITED_RETENTION
 
Fields inherited from interface de.cesr.lara.components.container.LaraContainer
UNLIMITED_CAPACITY
 
Constructor Summary
LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager)
           
LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager, int initialCapacity)
           
LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager, int initialCapacity, String name)
           
LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager, String name)
           
 
Method Summary
 void memoriseAll(Set<BOType> bos)
          Memorises the given set of behavioural options
 Set<BOType> recallAllMostRecent()
          Generic method that returns a collection of the most recently memorised BO for all behavioural options.
 
Methods inherited from class de.cesr.lara.components.container.memory.impl.LDefaultLimitedCapacityMemory
getCapacity, getCapacityManagementView, getCapacityManager, isFull, memorize, memorize, setCapacity, setCapacityManager
 
Methods inherited from class de.cesr.lara.components.container.memory.impl.LDefaultMemory
addMemoryPropertyObserver, clear, contains, contains, contains, contains, contains, createBackingStorage, forget, forget, forgetAll, forgetAll, getAllPropertyKeys, getDefaultRetentionTime, getName, getRetentionTime, getSize, isEmpty, iterator, recall, recall, recall, recall, recallAll, recallAll, recallAll, refresh, refresh, refresh, refresh, refresh, removeMemoryPropertyObserver, setDefaultRetentionTime, storageEventOccured, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 
Methods inherited from interface de.cesr.lara.components.container.memory.LaraMemory
addMemoryPropertyObserver, clear, contains, contains, contains, contains, contains, forget, forget, forgetAll, forgetAll, getAllPropertyKeys, getDefaultRetentionTime, getName, getRetentionTime, memorize, memorize, recall, recall, recall, recall, recallAll, recallAll, recallAll, refresh, refresh, refresh, refresh, refresh, removeMemoryPropertyObserver, setDefaultRetentionTime
 
Methods inherited from interface de.cesr.lara.components.container.LaraContainer
getCapacity, getSize, isEmpty, isFull
 
Methods inherited from interface java.lang.Iterable
iterator
 

Constructor Detail

LDefaultLimitedCapacityBOMemory

public LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager)
Parameters:
capacityManager -

LDefaultLimitedCapacityBOMemory

public LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager,
                                       int initialCapacity)
Parameters:
capacityManager -
initialCapacity -

LDefaultLimitedCapacityBOMemory

public LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager,
                                       int initialCapacity,
                                       String name)
Parameters:
capacityManager -
initialCapacity -
name - the memory's name

LDefaultLimitedCapacityBOMemory

public LDefaultLimitedCapacityBOMemory(LaraCapacityManager<BOType> capacityManager,
                                       String name)
Parameters:
capacityManager -
name - the memory's name
Method Detail

memoriseAll

public void memoriseAll(Set<BOType> bos)
Description copied from interface: LaraBOMemory
Memorises the given set of behavioural options

Specified by:
memoriseAll in interface LaraBOMemory<BOType extends LaraBehaviouralOption<?,? extends BOType>>
Parameters:
bos - behavioural options to memorise
See Also:
LaraBOMemory.memoriseAll(java.util.Set)

recallAllMostRecent

public Set<BOType> recallAllMostRecent()
                                                                                  throws LRetrieveException
Description copied from interface: LaraBOMemory
Generic method that returns a collection of the most recently memorised BO for all behavioural options.

Specified by:
recallAllMostRecent in interface LaraBOMemory<BOType extends LaraBehaviouralOption<?,? extends BOType>>
Returns:
for every behavioural option the one that was stored at last.
Throws:
LRetrieveException
See Also:
LaraBOMemory.recallAllMostRecent()