@FunctionalInterface public interface

RefCallback

com.atlassian.bitbucket.repository.RefCallback
Known Indirect Subclasses

Class Overview

A callback for streaming refs.

Summary

Public Methods
void onEnd(RefSummary summary)
Called after the final ref has been streamed.
boolean onRef(Ref ref)
Called to process a ref.
void onStart(RefContext context)
Called before the first ref is streamed.

Public Methods

public void onEnd (RefSummary summary)

Called after the final ref has been streamed.

Note: If there were no refs, this method may be called immediately after onStart(RefContext) without any calls to onRef(Ref).

Parameters
summary summarizes the request and the streamed refs
Throws
IOException May be thrown by implementations which perform I/O.

public boolean onRef (Ref ref)

Called to process a ref.

Parameters
ref the ref to stream
Returns
  • true if further refs should be streamed; otherwise, false to stop streaming
Throws
IOException May be thrown by implementations which perform I/O.

public void onStart (RefContext context)

Called before the first ref is streamed.

Parameters
context provides details about the request for which refs are being streamed
Throws
IOException May be thrown by implementations which perform I/O.