public abstract class AbstractCommitCallback extends Object implements CommitCallback
CommitCallback that provides no-op implementations for all methods.| Constructor and Description |
|---|
AbstractCommitCallback() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
onCommit(Commit commit)
Receives a fully-populated
commit for processing. |
void |
onEnd(CommitSummary summary)
Called after the final
commit has been streamed. |
void |
onStart(CommitContext context)
Called before the first
commit is streamed. |
public boolean onCommit(@Nonnull Commit commit) throws IOException
CommitCallbackcommit for processing.
This method will never be invoked before CommitCallback.onStart(CommitContext), and if it is invoked
CommitCallback.onEnd(CommitSummary) is guaranteed to be invoked, whether the end happens because this
method returns false or because the upstream sender runs out of commits.
onCommit in interface CommitCallbackcommit - ignoredtrueIOException - may be thrown by derived classespublic void onEnd(@Nonnull CommitSummary summary) throws IOException
CommitCallbackcommit has been streamed.
Note: If there were no commits, this method may be called immediately after CommitCallback.onStart(CommitContext)
without any calls to CommitCallback.onCommit(Commit).
onEnd in interface CommitCallbacksummary - ignoredIOException - may be thrown by derived classespublic void onStart(@Nonnull CommitContext context) throws IOException
CommitCallbackcommit is streamed.onStart in interface CommitCallbackcontext - ignoredIOException - may be thrown by derived classesCopyright © 2019 Atlassian. All rights reserved.