pub trait AsyncNotificationStore {
// Required methods
fn publish_hint(
&self,
authority_id: AuthorityId,
head: Head,
budget: WorkBudget,
cancellation: &CancellationToken,
) -> impl Future<Output = NotificationResult<()>>;
fn poll_hint_after(
&self,
authority_id: AuthorityId,
after: Head,
budget: WorkBudget,
cancellation: &CancellationToken,
) -> impl Future<Output = NotificationResult<NotificationPoll>>;
}Expand description
Runtime-neutral notification adapter suitable for browser and remote APIs.
Required Methods§
Sourcefn publish_hint(
&self,
authority_id: AuthorityId,
head: Head,
budget: WorkBudget,
cancellation: &CancellationToken,
) -> impl Future<Output = NotificationResult<()>>
fn publish_hint( &self, authority_id: AuthorityId, head: Head, budget: WorkBudget, cancellation: &CancellationToken, ) -> impl Future<Output = NotificationResult<()>>
Asynchronously publishes one disposable head hint.
§Errors
Returns cancellation, adapter, or exact work-budget failure.
Sourcefn poll_hint_after(
&self,
authority_id: AuthorityId,
after: Head,
budget: WorkBudget,
cancellation: &CancellationToken,
) -> impl Future<Output = NotificationResult<NotificationPoll>>
fn poll_hint_after( &self, authority_id: AuthorityId, after: Head, budget: WorkBudget, cancellation: &CancellationToken, ) -> impl Future<Output = NotificationResult<NotificationPoll>>
Asynchronously polls for a possibly newer hint.
§Errors
Returns cancellation, adapter, or exact work-budget failure.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".