Interface IEventRepository
public interface IEventRepository
-
Method Summary
Modifier and TypeMethodDescriptionvoid
deleteEventOccurrenceByActionId
(ActionId actionId) void
deleteValueChangeBlock
(PolicyId policyId, Map<String, String> variableValueChangeBlock) Provide concrete implementation for deletion of value changed .findAll()
findByActionId
(ActionId actionId) findByActionIdAndHistoricEventParametersAndOccurredAtMsBetween
(ActionId actionId, List<HistoricEventParameter> hep, long start, long end) findByActionIdAndMode
(ActionId actionId, String mode, List<HistoricEventParameter> policyEventParameters) findByActionIdAndOccurredAtMsBetweenParamIndependant
(ActionId actionId, long start, long end) long
findByOccurredAtMsAfterAndActionId
(long start, ActionId actionId) long
findByOccurredAtMsBeforeAndActionId
(long end, ActionId actionId) findByOccurredAtMsBetweenAndActionId
(long start, long end, ActionId actionId) Returns Map<ActionId, List>, Events with ActionId are to be stored. Returns Map<ActionId, List>, The parameters to save for that event getValueChanged
(String blockId, Policy policy) void
When PDP is notified via event then same call is passed to EventRepository.void
policyDeployed
(Policy policy) When policy is deployed call this method to update event storing map.void
policyRevoked
(Policy policy) When policy is revoked, this method needs to be called to update Map used to filter policy.void
policyUpdate
(Policy policy) When policy is updated, call this method.void
policyUpdate
(Policy policy, PolicyId oldPolicyId) When policy or the policyId is updated, call this method.void
reset()
Reset internal settings what events to save but does not clear the databasevoid
saveEventOccurrence
(Event event, Set<HistoricEventTrackItem> trackItems) Provide concrete implementation for storing of events.void
saveValueChangeBlock
(Policy policy, Map<String, String> variableValueChangeBlock) Provide concrete implementation for storing of value changed .void
setValueChanged
(Policy policy, String blockId, String valueInPolicy) void
updateValueChangeBlockPolicyId
(Policy newPolicy, PolicyId oldPolicyId) Provide concrete policyID update for the stored value changed .
-
Method Details
-
deleteEventOccurrenceByActionId
-
deleteValueChangeBlock
Provide concrete implementation for deletion of value changed .- Parameters:
policyId
- PolicyIdvariableValueChangeBlock
- Value change block with variable replaced with variable declaration xml block from policy
-
findAll
List<HistoricEvent> findAll() -
findByActionId
-
findByActionIdAndHistoricEventParametersAndOccurredAtMsBetween
List<HistoricEvent> findByActionIdAndHistoricEventParametersAndOccurredAtMsBetween(ActionId actionId, List<HistoricEventParameter> hep, long start, long end) -
findByActionIdAndMode
HistoricEvent findByActionIdAndMode(ActionId actionId, String mode, List<HistoricEventParameter> policyEventParameters) -
findByActionIdAndOccurredAtMsBetweenParamIndependant
List<HistoricEvent> findByActionIdAndOccurredAtMsBetweenParamIndependant(ActionId actionId, long start, long end) -
findByOccurredAtMsAfterAndActionId
-
findByOccurredAtMsBeforeAndActionId
-
findByOccurredAtMsBetweenAndActionId
-
getHistoricEventTrackItemsPerActionId
Map<ActionId,Set<HistoricEventTrackItem>> getHistoricEventTrackItemsPerActionId()Returns Map<ActionId, List>, The parameters to save for that event - Returns:
- Parameters of the event that needs to be stored
-
getEventsToBeStored
Returns Map<ActionId, List>, Events with ActionId are to be stored. - Returns:
-
getValueChanged
-
notify
When PDP is notified via event then same call is passed to EventRepository. EventRepository will take care of storing of events if required.- Parameters:
event
- notified.
-
policyDeployed
When policy is deployed call this method to update event storing map.- Parameters:
policy
- to be deployed
-
policyRevoked
When policy is revoked, this method needs to be called to update Map used to filter policy.- Parameters:
policy
- policy to be revoked
-
policyUpdate
When policy is updated, call this method.- Parameters:
policy
- Policy to be updated
-
policyUpdate
When policy or the policyId is updated, call this method.- Parameters:
policy
- Policy to be updatedoldPolicyId
- the previous/old policyId
-
saveEventOccurrence
Provide concrete implementation for storing of events.- Parameters:
event
- event to be storedtrackItems
- elements of the event that needs to be stored
-
saveValueChangeBlock
Provide concrete implementation for storing of value changed .- Parameters:
policy
- the policyvariableValueChangeBlock
- Value change block with variable replaced with variable declaration xml block from policy
-
setValueChanged
- Throws:
Exception
-
updateValueChangeBlockPolicyId
Provide concrete policyID update for the stored value changed .- Parameters:
newPolicy
- the new policy after policy editionoldPolicyId
- the old policyID
-
reset
void reset()Reset internal settings what events to save but does not clear the database
-