Class FilteredHandler
java.lang.Object
org.apache.jackrabbit.oak.plugins.observation.DefaultEventHandler
org.apache.jackrabbit.oak.plugins.observation.FilteredHandler
- All Implemented Interfaces:
EventHandler
Filtered event handler. This decorator class applies an
EventFilter
on all detected changes, and forwards the filtered change events to a given
delegate handler.-
Field Summary
Fields inherited from class org.apache.jackrabbit.oak.plugins.observation.DefaultEventHandler
INSTANCE
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Called before the given before and after states are compared.@Nullable EventHandler
getChildHandler
(String name, NodeState before, NodeState after) Returns a handler of events within the given child node, ornull
if changes within that child are not to be processed.void
Called after the given before and after states are compared.void
Notification for an added nodevoid
nodeDeleted
(String name, NodeState before) Notification for a deleted nodevoid
Notification for a moved nodevoid
nodeReordered
(String destName, String name, NodeState reordered) Notification for a reordered nodevoid
propertyAdded
(PropertyState after) Notification for an added propertyvoid
propertyChanged
(PropertyState before, PropertyState after) Notification for a changed propertyvoid
propertyDeleted
(PropertyState before) Notification for a deleted property
-
Constructor Details
-
FilteredHandler
-
-
Method Details
-
enter
Description copied from interface:EventHandler
Called before the given before and after states are compared. The implementation can use this method to initialize any internal state needed for processing the results of the comparison.- Specified by:
enter
in interfaceEventHandler
- Overrides:
enter
in classDefaultEventHandler
- Parameters:
before
- before state, non-existent if this node was addedafter
- after state, non-existent if this node was removed
-
leave
Description copied from interface:EventHandler
Called after the given before and after states are compared. The implementation can use this method to post-process information collected during the content diff.- Specified by:
leave
in interfaceEventHandler
- Overrides:
leave
in classDefaultEventHandler
- Parameters:
before
- before state, non-existent if this node was addedafter
- after state, non-existent if this node was removed
-
getChildHandler
@Nullable public @Nullable EventHandler getChildHandler(String name, NodeState before, NodeState after) Description copied from interface:EventHandler
Returns a handler of events within the given child node, ornull
if changes within that child are not to be processed.- Specified by:
getChildHandler
in interfaceEventHandler
- Overrides:
getChildHandler
in classDefaultEventHandler
- Parameters:
name
- name of the child nodebefore
- before state of the child node, possibly non-existentafter
- after state of the child node, possibly non-existent- Returns:
this
-
propertyAdded
Description copied from interface:EventHandler
Notification for an added property- Specified by:
propertyAdded
in interfaceEventHandler
- Overrides:
propertyAdded
in classDefaultEventHandler
- Parameters:
after
- added property
-
propertyChanged
Description copied from interface:EventHandler
Notification for a changed property- Specified by:
propertyChanged
in interfaceEventHandler
- Overrides:
propertyChanged
in classDefaultEventHandler
- Parameters:
before
- property before the changeafter
- property after the change
-
propertyDeleted
Description copied from interface:EventHandler
Notification for a deleted property- Specified by:
propertyDeleted
in interfaceEventHandler
- Overrides:
propertyDeleted
in classDefaultEventHandler
- Parameters:
before
- deleted property
-
nodeAdded
Description copied from interface:EventHandler
Notification for an added node- Specified by:
nodeAdded
in interfaceEventHandler
- Overrides:
nodeAdded
in classDefaultEventHandler
- Parameters:
name
- name of the nodeafter
- added node
-
nodeDeleted
Description copied from interface:EventHandler
Notification for a deleted node- Specified by:
nodeDeleted
in interfaceEventHandler
- Overrides:
nodeDeleted
in classDefaultEventHandler
- Parameters:
name
- name of the deleted nodebefore
- deleted node
-
nodeMoved
Description copied from interface:EventHandler
Notification for a moved node- Specified by:
nodeMoved
in interfaceEventHandler
- Overrides:
nodeMoved
in classDefaultEventHandler
- Parameters:
sourcePath
- source of the moved nodename
- name of the moved nodemoved
- moved node
-
nodeReordered
Description copied from interface:EventHandler
Notification for a reordered node- Specified by:
nodeReordered
in interfaceEventHandler
- Overrides:
nodeReordered
in classDefaultEventHandler
- Parameters:
destName
- name of theorderBefore()
destination nodename
- name of the moved nodereordered
- moved node
-