public interface PersistenceAdapter
AttributesManager to store skill attributes to a
persistence layer. The adapter encapsulates all initialization, get, and save logic specific to the persistence
implementation.| Modifier and Type | Method and Description |
|---|---|
void |
deleteAttributes(RequestEnvelope envelope)
Deletes attributes from persistence.
|
Optional<Map<String,Object>> |
getAttributes(RequestEnvelope envelope)
Retrieves attributes from persistence.
|
void |
saveAttributes(RequestEnvelope envelope,
Map<String,Object> attributes)
Saves attributes to persistence.
|
Optional<Map<String,Object>> getAttributes(RequestEnvelope envelope) throws PersistenceException
RequestEnvelope is passed to the adapter so current request
parameters can be used as an attribute key.envelope - the current request envelopeOptional containing existing attributes if they exist, or empty if notPersistenceException - if attributes could not be retrieved due to an errorvoid saveAttributes(RequestEnvelope envelope, Map<String,Object> attributes) throws PersistenceException
RequestEnvelope is passed to the adapter so current request parameters
can be used as an attribute key.envelope - the current request envelopeattributes - attributes to persistPersistenceException - if attributes could not be saved due to an errorvoid deleteAttributes(RequestEnvelope envelope) throws PersistenceException
RequestEnvelope is passed to the adapter so current request parameters
can be used as an attribute key.envelope - the current request envelope.PersistenceException - if attributes could not be deleted due to an error.Copyright © 2023. All rights reserved.