Trait iroh_bytes::provider::CustomGetHandler
source · pub trait CustomGetHandler: Send + Sync + Debug + 'static {
// Required method
fn handle(
&self,
token: Option<RequestToken>,
request: Bytes
) -> BoxFuture<'static, Result<GetRequest>>;
}Expand description
A custom get request handler that allows the user to make up a get request on the fly.
Required Methods§
sourcefn handle(
&self,
token: Option<RequestToken>,
request: Bytes
) -> BoxFuture<'static, Result<GetRequest>>
fn handle( &self, token: Option<RequestToken>, request: Bytes ) -> BoxFuture<'static, Result<GetRequest>>
Handle the custom request, given an opaque data blob from the requester.