Enum libp2p::kad::QueryInfo [−][src]
Information about a running query.
Variants
A query initiated by Kademlia::bootstrap.
Fields of Bootstrap
A query initiated by Kademlia::get_closest_peers.
A query initiated by Kademlia::get_providers.
Fields of GetProviders
key: KeyThe key for which to search for providers.
providers: HashSet<PeerId, RandomState>The found providers.
A (repeated) query initiated by Kademlia::start_providing.
Fields of AddProvider
key: KeyThe record key.
phase: AddProviderPhaseThe current phase of the query.
context: AddProviderContextThe execution context of the query.
A (repeated) query initiated by Kademlia::put_record.
Fields of PutRecord
record: Recordquorum: NonZeroUsizeThe expected quorum of responses w.r.t. the replication factor.
phase: PutRecordPhaseThe current phase of the query.
context: PutRecordContextThe execution context of the query.
A query initiated by Kademlia::get_record.
Fields of GetRecord
key: KeyThe key to look for.
records: Vec<PeerRecord, Global>The records with the id of the peer that returned them. None when
the record was found in the local store.
quorum: NonZeroUsizeThe number of records to look for.
cache_at: Option<Key<PeerId>>The closest peer to key that did not return a record.
When a record is found in a standard Kademlia query (quorum == 1), it is cached at this peer as soon as a record is found.
Trait Implementations
Auto Trait Implementations
impl RefUnwindSafe for QueryInfo
impl Send for QueryInfo
impl Sync for QueryInfo
impl Unpin for QueryInfo
impl UnwindSafe for QueryInfo
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut T[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> Same<T> for T[src]
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
pub fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>, [src]
V: MultiLane<T>,