Interface ActionVisitor
-
public interface ActionVisitor
Extension point called during population ofActionInfo
maps.Each visitor may mutate the input
ActionInfo
, or filter it out of the map entirely. When multiple extensions are registered, the order in which they are executed is undefined.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description boolean
visit(String name, ActionInfo actionInfo, ChangeInfo changeInfo)
Visit a change-level action.boolean
visit(String name, ActionInfo actionInfo, ChangeInfo changeInfo, RevisionInfo revisionInfo)
Visit a revision-level action.
-
-
-
Method Detail
-
visit
boolean visit(String name, ActionInfo actionInfo, ChangeInfo changeInfo)
Visit a change-level action.Callers may mutate the input
ActionInfo
, or return false to omit the action from the map entirely. Inputs other than theActionInfo
should be considered immutable.- Parameters:
name
- name of the action, as a key into theActionInfo
map returned by the REST API.actionInfo
- action being visited; caller may mutate.changeInfo
- information about the change to which this action belongs; caller should treat as immutable.- Returns:
- true if the action should remain in the map, or false to omit it.
-
visit
boolean visit(String name, ActionInfo actionInfo, ChangeInfo changeInfo, RevisionInfo revisionInfo)
Visit a revision-level action.Callers may mutate the input
ActionInfo
, or return false to omit the action from the map entirely. Inputs other than theActionInfo
should be considered immutable.- Parameters:
name
- name of the action, as a key into theActionInfo
map returned by the REST API.actionInfo
- action being visited; caller may mutate.changeInfo
- information about the change to which this action belongs; caller should treat as immutable.revisionInfo
- information about the revision to which this action belongs; caller should treat as immutable.- Returns:
- true if the action should remain in the map, or false to omit it.
-
-