Class JCacheUnsolicitedFragmentationStorage
java.lang.Object
org.openehealth.ipf.commons.ihe.hl7v2.storage.JCacheUnsolicitedFragmentationStorage
- All Implemented Interfaces:
UnsolicitedFragmentationStorage
- Direct Known Subclasses:
EhcacheUnsolicitedFragmentationStorage
public class JCacheUnsolicitedFragmentationStorage
extends Object
implements UnsolicitedFragmentationStorage
A storage of HL7 v2 unsolicited fragmentation accumulators.
- Author:
- Dmytro Rud
-
Constructor Summary
ConstructorsConstructorDescriptionJCacheUnsolicitedFragmentationStorage(javax.cache.Cache<String, StringBuilder> cache) -
Method Summary
Modifier and TypeMethodDescriptiongetAndRemove(String key) Returns the fragment accumulator which corresponds to the given key and removes it from the storage.voidput(String key, StringBuilder accumulator) Puts a fragment accumulator into the storage.
-
Constructor Details
-
JCacheUnsolicitedFragmentationStorage
-
-
Method Details
-
put
Description copied from interface:UnsolicitedFragmentationStoragePuts a fragment accumulator into the storage.- Specified by:
putin interfaceUnsolicitedFragmentationStorage- Parameters:
key- Key consisting of MSH-14/DSC-1, MSH-3-1, MSH-3-2, MSH-3-3.accumulator- Accumulator to be stored.
-
getAndRemove
Description copied from interface:UnsolicitedFragmentationStorageReturns the fragment accumulator which corresponds to the given key and removes it from the storage.- Specified by:
getAndRemovein interfaceUnsolicitedFragmentationStorage- Parameters:
key- Key consisting of MSH-14/DCS-1, MSH-3-1, MSH-3-2, MSH-3-3.- Returns:
- Accumulator or
nullwhen none found.
-