pub struct Sender<T>(/* private fields */);
Expand description

The transmission end of a bounded mpsc channel.

This value is created by the channel function.

Implementations§

source§

impl<T> Sender<T>

source

pub fn try_send(&mut self, msg: T) -> Result<(), TrySendError<T>>

Attempts to send a message on this Sender, returning the message if there was an error.

source

pub fn start_send(&mut self, msg: T) -> Result<(), SendError>

Send a message on the channel.

This function should only be called after poll_ready has reported that the channel is ready to receive a message.

source

pub fn poll_ready( &mut self, cx: &mut Context<'_> ) -> Poll<Result<(), SendError>>

Polls the channel to determine if there is guaranteed capacity to send at least one item without waiting.

§Return value

This method returns:

  • Poll::Ready(Ok(_)) if there is sufficient capacity;
  • Poll::Pending if the channel may not have capacity, in which case the current task is queued to be notified once capacity is available;
  • Poll::Ready(Err(SendError)) if the receiver has been dropped.
source

pub fn is_closed(&self) -> bool

Returns whether this channel is closed without needing a context.

source

pub fn close_channel(&mut self)

Closes this channel from the sender side, preventing any new messages.

source

pub fn disconnect(&mut self)

Disconnects this sender from the channel, closing it if there are no more senders left.

source

pub fn same_receiver(&self, other: &Sender<T>) -> bool

Returns whether the senders send to the same receiver.

source

pub fn is_connected_to(&self, receiver: &Receiver<T>) -> bool

Returns whether the sender send to this receiver.

source

pub fn hash_receiver<H>(&self, hasher: &mut H)
where H: Hasher,

Hashes the receiver into the provided hasher

Trait Implementations§

source§

impl<T> Clone for Sender<T>

source§

fn clone(&self) -> Sender<T>

Returns a copy of the value. Read more
1.0.0 · source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
source§

impl<T> Debug for Sender<T>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result<(), Error>

Formats the value using the given formatter. Read more
source§

impl<E> GhostChannelSender<E> for Sender<E>
where E: GhostEvent,

source§

fn ghost_actor_channel_send( &self, event: E ) -> MustBoxFuture<'static, Result<(), GhostError>>

Forward a GhostEvent along this channel.
source§

impl<T> Sink<T> for Sender<T>

§

type Error = SendError

The type of value produced by the sink when an error occurs.
source§

fn poll_ready( self: Pin<&mut Sender<T>>, cx: &mut Context<'_> ) -> Poll<Result<(), <Sender<T> as Sink<T>>::Error>>

Attempts to prepare the Sink to receive a value. Read more
source§

fn start_send( self: Pin<&mut Sender<T>>, msg: T ) -> Result<(), <Sender<T> as Sink<T>>::Error>

Begin the process of sending a value to the sink. Each call to this function must be preceded by a successful call to poll_ready which returned Poll::Ready(Ok(())). Read more
source§

fn poll_flush( self: Pin<&mut Sender<T>>, cx: &mut Context<'_> ) -> Poll<Result<(), <Sender<T> as Sink<T>>::Error>>

Flush any remaining output from this sink. Read more
source§

fn poll_close( self: Pin<&mut Sender<T>>, _: &mut Context<'_> ) -> Poll<Result<(), <Sender<T> as Sink<T>>::Error>>

Flush any remaining output and close this sink, if necessary. Read more

Auto Trait Implementations§

§

impl<T> !RefUnwindSafe for Sender<T>

§

impl<T> Send for Sender<T>
where T: Send,

§

impl<T> Sync for Sender<T>
where T: Send,

§

impl<T> Unpin for Sender<T>

§

impl<T> !UnwindSafe for Sender<T>

Blanket Implementations§

source§

impl<T> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Any for T
where T: Any,

source§

fn into_any(self: Box<T>) -> Box<dyn Any>

source§

fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>

source§

fn type_name(&self) -> &'static str

source§

impl<T> AnySync for T
where T: Any + Send + Sync,

source§

fn into_any_arc(self: Arc<T>) -> Arc<dyn Any + Sync + Send>

source§

impl<T> ArchivePointee for T

§

type ArchivedMetadata = ()

The archived version of the pointer metadata for this type.
source§

fn pointer_metadata( _: &<T as ArchivePointee>::ArchivedMetadata ) -> <T as Pointee>::Metadata

Converts some archived metadata to the pointer metadata for itself.
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<F, W, T, D> Deserialize<With<T, W>, D> for F
where W: DeserializeWith<F, T, D>, D: Fallible + ?Sized, F: ?Sized,

source§

fn deserialize( &self, deserializer: &mut D ) -> Result<With<T, W>, <D as Fallible>::Error>

Deserializes using the given deserializer
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> FutureExt for T

source§

fn with_context(self, otel_cx: Context) -> WithContext<Self>

Attaches the provided Context to this type, returning a WithContext wrapper. Read more
source§

fn with_current_context(self) -> WithContext<Self>

Attaches the current Context to this type, returning a WithContext wrapper. Read more
source§

impl<S> HolochainP2pEventSender for S

source§

fn put_agent_info_signed( &self, dna_hash: HoloHash<Dna>, peer_data: Vec<AgentInfoSigned> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

We need to store signed agent info.
source§

fn query_agent_info_signed( &self, dna_hash: HoloHash<Dna>, agents: Option<HashSet<Arc<KitsuneAgent>>>, kitsune_space: Arc<KitsuneSpace> ) -> MustBoxFuture<'static, Result<Vec<AgentInfoSigned>, HolochainP2pError>>

We need to get previously stored agent info. The optional agents parameter is an include filter. This can be thought of as a way to filter a held list of agents against the current state of the store.
source§

fn query_gossip_agents( &self, dna_hash: HoloHash<Dna>, agents: Option<Vec<HoloHash<Agent>>>, kitsune_space: Arc<KitsuneSpace>, since_ms: u64, until_ms: u64, arc_set: Arc<DhtArcSet> ) -> MustBoxFuture<'static, Result<Vec<AgentInfoSigned>, HolochainP2pError>>

We need to get agents that fit into an arc set for gossip.
source§

fn query_agent_info_signed_near_basis( &self, dna_hash: HoloHash<Dna>, kitsune_space: Arc<KitsuneSpace>, basis_loc: u32, limit: u32 ) -> MustBoxFuture<'static, Result<Vec<AgentInfoSigned>, HolochainP2pError>>

query agent info in order of closeness to a basis location.
source§

fn query_peer_density( &self, dna_hash: HoloHash<Dna>, kitsune_space: Arc<KitsuneSpace>, dht_arc: DhtArc ) -> MustBoxFuture<'static, Result<PeerView, HolochainP2pError>>

Query the peer density of a space for a given [DhtArc].
source§

fn call_remote( &self, dna_hash: HoloHash<Dna>, from_agent: HoloHash<Agent>, signature: Signature, to_agent: HoloHash<Agent>, zome_name: ZomeName, fn_name: FunctionName, cap_secret: Option<CapSecret>, payload: ExternIO, nonce: Nonce256Bits, expires_at: Timestamp ) -> MustBoxFuture<'static, Result<SerializedBytes, HolochainP2pError>>

A remote node is attempting to make a remote call on us.
source§

fn publish( &self, dna_hash: HoloHash<Dna>, request_validation_receipt: bool, countersigning_session: bool, ops: Vec<DhtOp> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

A remote node is publishing data in a range we claim to be holding.
source§

fn get( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, dht_hash: HoloHash<AnyDht>, options: GetOptions ) -> MustBoxFuture<'static, Result<WireOps, HolochainP2pError>>

A remote node is requesting entry data from us.
source§

fn get_meta( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, dht_hash: HoloHash<AnyDht>, options: GetMetaOptions ) -> MustBoxFuture<'static, Result<MetadataSet, HolochainP2pError>>

A remote node is requesting metadata from us.
A remote node is requesting link data from us.
A remote node is requesting a link count from us.
source§

fn get_agent_activity( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, agent: HoloHash<Agent>, query: ChainQueryFilter, options: GetActivityOptions ) -> MustBoxFuture<'static, Result<AgentActivityResponse<HoloHash<Action>>, HolochainP2pError>>

A remote node is requesting agent activity from us.
source§

fn must_get_agent_activity( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, author: HoloHash<Agent>, filter: ChainFilter ) -> MustBoxFuture<'static, Result<MustGetAgentActivityResponse, HolochainP2pError>>

A remote node is requesting agent activity from us.
source§

fn validation_receipts_received( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, receipts: ValidationReceiptBundle ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

A remote node has sent us a validation receipt.
source§

fn query_op_hashes( &self, dna_hash: HoloHash<Dna>, arc_set: DhtArcSet, window: Range<Timestamp>, max_ops: usize, include_limbo: bool ) -> MustBoxFuture<'static, Result<Option<(Vec<HoloHash<DhtOp>>, RangeInclusive<Timestamp>)>, HolochainP2pError>>

The p2p module wishes to query our DhtOpHash store. Gets all ops from a set of agents within a time window and max number of ops. Returns the actual time window of returned ops as well.
source§

fn fetch_op_data( &self, dna_hash: HoloHash<Dna>, query: FetchOpDataQuery ) -> MustBoxFuture<'static, Result<Vec<(HoloHash<DhtOp>, DhtOp)>, HolochainP2pError>>

The p2p module needs access to the content for a given set of DhtOpHashes.
source§

fn sign_network_data( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, data: Vec<u8> ) -> MustBoxFuture<'static, Result<Signature, HolochainP2pError>>

P2p operations require cryptographic signatures and validation.
source§

fn countersigning_session_negotiation( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, message: CountersigningSessionNegotiationMessage ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Messages between agents that drive a countersigning session.
source§

impl<S> HolochainP2pSender for S

source§

fn join( &self, dna_hash: HoloHash<Dna>, agent_pub_key: HoloHash<Agent>, maybe_agent_info: Option<AgentInfoSigned>, initial_arc: Option<DhtArc> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

The p2p module must be informed at runtime which dna/agent pairs it should be tracking.
source§

fn leave( &self, dna_hash: HoloHash<Dna>, agent_pub_key: HoloHash<Agent> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

If a cell is disabled, we’ll need to "leave" the network module as well.
source§

fn call_remote( &self, dna_hash: HoloHash<Dna>, from_agent: HoloHash<Agent>, signature: Signature, to_agent: HoloHash<Agent>, zome_name: ZomeName, fn_name: FunctionName, cap_secret: Option<CapSecret>, payload: ExternIO, nonce: Nonce256Bits, expires_at: Timestamp ) -> MustBoxFuture<'static, Result<SerializedBytes, HolochainP2pError>>

Invoke a zome function on a remote node (if you have been granted the capability).
source§

fn remote_signal( &self, dna_hash: HoloHash<Dna>, from_agent: HoloHash<Agent>, to_agent_list: Vec<(Signature, HoloHash<Agent>)>, zome_name: ZomeName, fn_name: FunctionName, cap: Option<CapSecret>, payload: ExternIO, nonce: Nonce256Bits, expires_at: Timestamp ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Invoke a zome function on a remote node (if you have been granted the capability). This is a fire-and-forget operation, a best effort will be made to forward the signal, but if the conductor network is overworked it may decide not to deliver some of the signals.
source§

fn publish( &self, dna_hash: HoloHash<Dna>, request_validation_receipt: bool, countersigning_session: bool, basis_hash: HoloHash<AnyLinkable>, source: HoloHash<Agent>, op_hash_list: Vec<RoughSized<Arc<KitsuneOpHash>>>, timeout_ms: Option<u64>, reflect_ops: Option<Vec<DhtOp>> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Publish data to the correct neighborhood.
source§

fn publish_countersign( &self, dna_hash: HoloHash<Dna>, flag: bool, basis_hash: HoloHash<AnyLinkable>, op: DhtOp ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Publish a countersigning op.
source§

fn get( &self, dna_hash: HoloHash<Dna>, dht_hash: HoloHash<AnyDht>, options: GetOptions ) -> MustBoxFuture<'static, Result<Vec<WireOps>, HolochainP2pError>>

Get an entry from the DHT.
source§

fn get_meta( &self, dna_hash: HoloHash<Dna>, dht_hash: HoloHash<AnyDht>, options: GetMetaOptions ) -> MustBoxFuture<'static, Result<Vec<MetadataSet>, HolochainP2pError>>

Get metadata from the DHT.
Get links from the DHT.
Get a count of links from the DHT.
source§

fn get_agent_activity( &self, dna_hash: HoloHash<Dna>, agent: HoloHash<Agent>, query: ChainQueryFilter, options: GetActivityOptions ) -> MustBoxFuture<'static, Result<Vec<AgentActivityResponse<HoloHash<Action>>>, HolochainP2pError>>

Get agent activity from the DHT.
source§

fn must_get_agent_activity( &self, dna_hash: HoloHash<Dna>, author: HoloHash<Agent>, filter: ChainFilter ) -> MustBoxFuture<'static, Result<Vec<MustGetAgentActivityResponse>, HolochainP2pError>>

A remote node is requesting agent activity from us.
source§

fn send_validation_receipts( &self, dna_hash: HoloHash<Dna>, to_agent: HoloHash<Agent>, receipts: ValidationReceiptBundle ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Send a validation receipt to a remote node.
source§

fn new_integrated_data( &self, dna_hash: HoloHash<Dna> ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

New data has been integrated and is ready for gossiping.
source§

fn authority_for_hash( &self, dna_hash: HoloHash<Dna>, basis: HoloHash<AnyLinkable> ) -> MustBoxFuture<'static, Result<bool, HolochainP2pError>>

Check if any local agent in this space is an authority for a hash.
source§

fn countersigning_session_negotiation( &self, dna_hash: HoloHash<Dna>, agents: Vec<HoloHash<Agent>>, message: CountersigningSessionNegotiationMessage ) -> MustBoxFuture<'static, Result<(), HolochainP2pError>>

Messages between agents negotiation a countersigning session.
source§

fn dump_network_metrics( &self, dna_hash: Option<HoloHash<Dna>> ) -> MustBoxFuture<'static, Result<String, HolochainP2pError>>

Dump network metrics.
source§

fn dump_network_stats( &self ) -> MustBoxFuture<'static, Result<String, HolochainP2pError>>

Dump network stats.
source§

fn get_diagnostics( &self, dna_hash: HoloHash<Dna> ) -> MustBoxFuture<'static, Result<KitsuneDiagnostics, HolochainP2pError>>

Get struct for diagnostic data
source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<S> KitsuneP2pEventSender for S

source§

fn put_agent_info_signed( &self, input: PutAgentInfoSignedEvt ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

We need to store signed agent info.
source§

fn query_agents( &self, input: QueryAgentsEvt ) -> MustBoxFuture<'static, Result<Vec<AgentInfoSigned>, KitsuneP2pError>>

We need to get previously stored agent info.
source§

fn query_peer_density( &self, space: Arc<KitsuneSpace>, dht_arc: DhtArc ) -> MustBoxFuture<'static, Result<PeerView, KitsuneP2pError>>

Query the peer density of a space for a given [DhtArc].
source§

fn call( &self, space: Arc<KitsuneSpace>, to_agent: Arc<KitsuneAgent>, payload: Vec<u8> ) -> MustBoxFuture<'static, Result<Vec<u8>, KitsuneP2pError>>

We are receiving a request from a remote node.
source§

fn notify( &self, space: Arc<KitsuneSpace>, to_agent: Arc<KitsuneAgent>, payload: Vec<u8> ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

We are receiving a notification from a remote node.
source§

fn receive_ops( &self, space: Arc<KitsuneSpace>, ops: Vec<Arc<KitsuneOpData>>, context: Option<FetchContext> ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

We have received ops to be integrated, either through gossip or publish.
source§

fn query_op_hashes( &self, input: QueryOpHashesEvt ) -> MustBoxFuture<'static, Result<Option<(Vec<Arc<KitsuneOpHash>>, RangeInclusive<Timestamp>)>, KitsuneP2pError>>

Gather a list of op-hashes from our implementor that meet criteria. Get the oldest and newest times for ops within a time window and max number of ops.
source§

fn fetch_op_data( &self, input: FetchOpDataEvt ) -> MustBoxFuture<'static, Result<Vec<(Arc<KitsuneOpHash>, Arc<KitsuneOpData>)>, KitsuneP2pError>>

Gather all op-hash data for a list of op-hashes from our implementor.
source§

fn sign_network_data( &self, input: SignNetworkDataEvt ) -> MustBoxFuture<'static, Result<KitsuneSignature, KitsuneP2pError>>

Request that our implementor sign some data on behalf of an agent.
source§

impl<S> KitsuneP2pSender for S

source§

fn list_transport_bindings( &self ) -> MustBoxFuture<'static, Result<Vec<Url2>, KitsuneP2pError>>

Get the calculated transport bindings.
source§

fn join( &self, space: Arc<KitsuneSpace>, agent: Arc<KitsuneAgent>, maybe_agent_info: Option<AgentInfoSigned>, initial_arc: Option<DhtArc> ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

Announce a space/agent pair on this network.
source§

fn leave( &self, space: Arc<KitsuneSpace>, agent: Arc<KitsuneAgent> ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

Withdraw this space/agent pair from this network.
source§

fn rpc_single( &self, space: Arc<KitsuneSpace>, to_agent: Arc<KitsuneAgent>, payload: Vec<u8>, timeout_ms: Option<u64> ) -> MustBoxFuture<'static, Result<Vec<u8>, KitsuneP2pError>>

Make a request of a single remote agent, expecting a response. The remote side will receive a “Call” event.
source§

fn rpc_multi( &self, input: RpcMulti ) -> MustBoxFuture<'static, Result<Vec<RpcMultiResponse>, KitsuneP2pError>>

Make a request to multiple destination agents - awaiting/aggregating the responses. The remote sides will see these messages as “Call” events. NOTE: We’ve currently disabled the “multi” part of this. It will still pick appropriate peers by basis, but will only make requests one at a time, returning the first success.
source§

fn broadcast( &self, space: Arc<KitsuneSpace>, basis: Arc<KitsuneBasis>, timeout: KitsuneTimeout, data: BroadcastData ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

Publish data to a “neighborhood” of remote nodes surrounding the “basis” hash. This is a multi-step fire-and-forget algorithm. An Ok(()) result only means that we were able to establish at least one connection with a node in the target neighborhood. The remote sides will see these messages as “Notify” events.
source§

fn targeted_broadcast( &self, space: Arc<KitsuneSpace>, agents: Vec<Arc<KitsuneAgent>>, timeout: KitsuneTimeout, payload: Vec<u8>, drop_at_limit: bool ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

Broadcast data to a specific set of agents without expecting a response. An Ok(()) result only means that we were able to establish at least one connection with a node in the agent set.
source§

fn new_integrated_data( &self, space: Arc<KitsuneSpace> ) -> MustBoxFuture<'static, Result<(), KitsuneP2pError>>

New data has been integrated and is ready for gossiping.
source§

fn authority_for_hash( &self, space: Arc<KitsuneSpace>, basis: Arc<KitsuneBasis> ) -> MustBoxFuture<'static, Result<bool, KitsuneP2pError>>

Check if an agent is an authority for a hash.
source§

fn dump_network_metrics( &self, space: Option<Arc<KitsuneSpace>> ) -> MustBoxFuture<'static, Result<Value, KitsuneP2pError>>

dump network metrics
source§

fn dump_network_stats( &self ) -> MustBoxFuture<'static, Result<Value, KitsuneP2pError>>

dump network stats
source§

fn get_diagnostics( &self, space: Arc<KitsuneSpace> ) -> MustBoxFuture<'static, Result<KitsuneDiagnostics, KitsuneP2pError>>

Get data for diagnostics
source§

impl<T> LayoutRaw for T

source§

fn layout_raw(_: <T as Pointee>::Metadata) -> Result<Layout, LayoutError>

Gets the layout of the type.
source§

impl<T> Pointable for T

source§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T> Pointee for T

§

type Metadata = ()

The type for metadata in pointers and references to Self.
source§

impl<T> Same for T

§

type Output = T

Should always be Self
source§

impl<T, Item> SinkExt<Item> for T
where T: Sink<Item> + ?Sized,

source§

fn with<U, Fut, F, E>(self, f: F) -> With<Self, Item, U, Fut, F>
where F: FnMut(U) -> Fut, Fut: Future<Output = Result<Item, E>>, E: From<Self::Error>, Self: Sized,

Composes a function in front of the sink. Read more
source§

fn with_flat_map<U, St, F>(self, f: F) -> WithFlatMap<Self, Item, U, St, F>
where F: FnMut(U) -> St, St: Stream<Item = Result<Item, Self::Error>>, Self: Sized,

Composes a function in front of the sink. Read more
source§

fn sink_map_err<E, F>(self, f: F) -> SinkMapErr<Self, F>
where F: FnOnce(Self::Error) -> E, Self: Sized,

Transforms the error returned by the sink.
source§

fn sink_err_into<E>(self) -> SinkErrInto<Self, Item, E>
where Self: Sized, Self::Error: Into<E>,

Map this sink’s error to a different error type using the Into trait. Read more
source§

fn buffer(self, capacity: usize) -> Buffer<Self, Item>
where Self: Sized,

Adds a fixed-size buffer to the current sink. Read more
source§

fn close(&mut self) -> Close<'_, Self, Item>
where Self: Unpin,

Close the sink.
source§

fn fanout<Si>(self, other: Si) -> Fanout<Self, Si>
where Self: Sized, Item: Clone, Si: Sink<Item, Error = Self::Error>,

Fanout items to multiple sinks. Read more
source§

fn flush(&mut self) -> Flush<'_, Self, Item>
where Self: Unpin,

Flush the sink, processing all pending items. Read more
source§

fn send(&mut self, item: Item) -> Send<'_, Self, Item>
where Self: Unpin,

A future that completes after the given item has been fully processed into the sink, including flushing. Read more
source§

fn feed(&mut self, item: Item) -> Feed<'_, Self, Item>
where Self: Unpin,

A future that completes after the given item has been received by the sink. Read more
source§

fn send_all<'a, St>(&'a mut self, stream: &'a mut St) -> SendAll<'a, Self, St>
where St: TryStream<Ok = Item, Error = Self::Error> + Stream + Unpin + ?Sized, Self: Unpin,

A future that completes after the given stream has been fully processed into the sink, including flushing. Read more
source§

fn left_sink<Si2>(self) -> Either<Self, Si2>
where Si2: Sink<Item, Error = Self::Error>, Self: Sized,

Wrap this sink in an Either sink, making it the left-hand variant of that Either. Read more
source§

fn right_sink<Si1>(self) -> Either<Si1, Self>
where Si1: Sink<Item, Error = Self::Error>, Self: Sized,

Wrap this stream in an Either stream, making it the right-hand variant of that Either. Read more
source§

fn poll_ready_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<(), Self::Error>>
where Self: Unpin,

A convenience method for calling Sink::poll_ready on Unpin sink types.
source§

fn start_send_unpin(&mut self, item: Item) -> Result<(), Self::Error>
where Self: Unpin,

A convenience method for calling Sink::start_send on Unpin sink types.
source§

fn poll_flush_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<(), Self::Error>>
where Self: Unpin,

A convenience method for calling Sink::poll_flush on Unpin sink types.
source§

fn poll_close_unpin( &mut self, cx: &mut Context<'_> ) -> Poll<Result<(), Self::Error>>
where Self: Unpin,

A convenience method for calling Sink::poll_close on Unpin sink types.
source§

impl<Item, S> SinkRateLimitExt<Item, S> for S
where S: Sink<Item>,

source§

fn ratelimit_sink<D, C>( self, limiter: &RateLimiter<NotKeyed, D, C> ) -> RatelimitedSink<'_, Item, S, D, C>

Limits the rate at which items can be put into the current sink.
source§

fn ratelimit_sink_with_jitter<D, C>( self, limiter: &RateLimiter<NotKeyed, D, C>, jitter: Jitter ) -> RatelimitedSink<'_, Item, S, D, C>

Limits the rate at which items can be put into the current sink, with a randomized wait period.
source§

impl<SS, SP> SupersetOf<SS> for SP
where SS: SubsetOf<SP>,

source§

fn to_subset(&self) -> Option<SS>

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more
source§

fn is_in_subset(&self) -> bool

Checks if self is actually part of its subset T (and can be converted to it).
source§

fn to_subset_unchecked(&self) -> SS

Use with care! Same as self.to_subset but without any property checks. Always succeeds.
source§

fn from_subset(element: &SS) -> SP

The inclusion map: converts self to the equivalent element of its superset.
source§

impl<T> ToOwned for T
where T: Clone,

§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> Upcastable for T
where T: Any + Send + Sync + 'static,

source§

fn upcast_any_ref(&self) -> &(dyn Any + 'static)

upcast ref
source§

fn upcast_any_mut(&mut self) -> &mut (dyn Any + 'static)

upcast mut ref
source§

fn upcast_any_box(self: Box<T>) -> Box<dyn Any>

upcast boxed dyn
source§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

source§

fn vzip(self) -> V

source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

impl<T> State for T
where T: Debug + Clone + Send + Sync,