pub struct SvsServiceDiscovery { /* private fields */ }Expand description
SVS-backed push service-record discovery.
Add alongside ServiceDiscoveryProtocol in a CompositeDiscovery to
receive push notifications whenever a peer publishes or updates a service
record.
Implementations§
Trait Implementations§
Source§impl DiscoveryProtocol for SvsServiceDiscovery
impl DiscoveryProtocol for SvsServiceDiscovery
Source§fn protocol_id(&self) -> ProtocolId
fn protocol_id(&self) -> ProtocolId
Unique protocol identifier.
Source§fn claimed_prefixes(&self) -> &[Name]
fn claimed_prefixes(&self) -> &[Name]
NDN name prefixes this protocol reserves. Read more
Source§fn on_face_up(&self, _face_id: FaceId, _ctx: &dyn DiscoveryContext)
fn on_face_up(&self, _face_id: FaceId, _ctx: &dyn DiscoveryContext)
Called when a new face comes up (after
FaceTable::insert).Source§fn on_face_down(&self, _face_id: FaceId, _ctx: &dyn DiscoveryContext)
fn on_face_down(&self, _face_id: FaceId, _ctx: &dyn DiscoveryContext)
Called when a face goes down (before
FaceTable::remove).Source§fn on_inbound(
&self,
raw: &Bytes,
_incoming_face: FaceId,
_meta: &InboundMeta,
_ctx: &dyn DiscoveryContext,
) -> bool
fn on_inbound( &self, raw: &Bytes, _incoming_face: FaceId, _meta: &InboundMeta, _ctx: &dyn DiscoveryContext, ) -> bool
Called for every inbound raw packet before it enters the pipeline. Read more
Source§fn on_tick(&self, now: Instant, ctx: &dyn DiscoveryContext)
fn on_tick(&self, now: Instant, ctx: &dyn DiscoveryContext)
Periodic tick, called by the engine’s tick task at
tick_interval. Read moreSource§fn tick_interval(&self) -> Duration
fn tick_interval(&self) -> Duration
How often the engine should call
on_tick. Read moreAuto Trait Implementations§
impl !Freeze for SvsServiceDiscovery
impl RefUnwindSafe for SvsServiceDiscovery
impl Send for SvsServiceDiscovery
impl Sync for SvsServiceDiscovery
impl Unpin for SvsServiceDiscovery
impl UnwindSafe for SvsServiceDiscovery
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more