Class CompositeHook
java.lang.Object
org.apache.jackrabbit.oak.spi.commit.CompositeHook
- All Implemented Interfaces:
CommitHook
Composite commit hook. Maintains a list of component hooks and takes
care of calling them in proper sequence.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic CommitHook
compose
(@NotNull Collection<CommitHook> hooks) @NotNull NodeState
processCommit
(NodeState before, NodeState after, CommitInfo info) Validates and/or modifies the given content change before it gets persisted.
-
Constructor Details
-
CompositeHook
-
-
Method Details
-
compose
-
processCommit
@NotNull public @NotNull NodeState processCommit(NodeState before, NodeState after, CommitInfo info) throws CommitFailedException Description copied from interface:CommitHook
Validates and/or modifies the given content change before it gets persisted.- Specified by:
processCommit
in interfaceCommitHook
- Parameters:
before
- content tree before the commitafter
- content tree prepared for the commitinfo
- metadata associated with this commit- Returns:
- content tree to be committed
- Throws:
CommitFailedException
- if the commit should be rejected
-