Class EditorHook
java.lang.Object
org.apache.jackrabbit.oak.spi.commit.EditorHook
- All Implemented Interfaces:
CommitHook
This commit hook implementation processes changes to be committed
using the
Editor instance provided by the EditorProvider
passed to the constructor.- Since:
- Oak 0.7
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription@NotNull NodeStateprocessCommit(@NotNull NodeState before, @NotNull NodeState after, @NotNull CommitInfo info) Validates and/or modifies the given content change before it gets persisted.toString()
-
Constructor Details
-
EditorHook
-
-
Method Details
-
processCommit
@NotNull public @NotNull NodeState processCommit(@NotNull @NotNull NodeState before, @NotNull @NotNull NodeState after, @NotNull @NotNull CommitInfo info) throws org.apache.jackrabbit.oak.api.CommitFailedException Description copied from interface:CommitHookValidates and/or modifies the given content change before it gets persisted.- Specified by:
processCommitin 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:
org.apache.jackrabbit.oak.api.CommitFailedException- if the commit should be rejected
-
toString
-