weave-swarm · runtime::substream
Source declarations, signatures and documentation for runtime::substream.
Source: sigil/weave/network/weave-swarm/src/runtime/substream.rs. SHA-256: 0977e86eade4fedf76193ec9ebcf0a975f9bc83c328a7b5d40202516c1175ff2.
This reference follows declared source modules, retains conditional attributes, and includes public declarations and implementation methods. Private-module re-exports and trait resolution require the compiler; this is a source reference, not a claim that every listed item is a root import. Function bodies and constant values are omitted.
runtime::substream::CanonicalTransportPeerId
Canonical binary inline-Ed25519 libp2p PeerId bytes.
The field is private, there is no serde/default conversion, and construction is crate-restricted to the version-pinned validator path.
#[derive(Clone, PartialEq, Eq, PartialOrd, Ord, Hash)]
pub struct CanonicalTransportPeerId(Arc<[u8]>);Source line: 23.
runtime::substream::CanonicalTransportPeerId::as_bytes
pub fn as_bytes(&self) -> &[u8];Source line: 52.
runtime::substream::TransportRole
Role of the local peer in the authenticated transport connection.
#[derive(Debug, Clone, Copy, PartialEq, Eq)]
pub enum TransportRole {
Initiator,
Responder,
}Source line: 59.
runtime::substream::RoleOrderedTransportPeerIds
Canonical initiator/responder ordering required by T-B transcripts.
#[derive(Debug, Clone, PartialEq, Eq)]
pub struct RoleOrderedTransportPeerIds {
pub initiator: CanonicalTransportPeerId,
pub responder: CanonicalTransportPeerId
}Source line: 66.
runtime::substream::AuthenticatedSubstream
Non-forgeable arbitrary authenticated application substream.
This type carries transport facts only and grants no application authority. It retains the global stream permit and raw stream in an actor-shared lifetime slot. Dropping it performs one nonblocking release transition; accounting is released only after typed backend close/reset acknowledgement or authoritative connection teardown.
pub struct AuthenticatedSubstream<S>
where
S: AsyncRead + AsyncWrite + Unpin + Send + 'static, {
}Source line: 200.
runtime::substream::AuthenticatedSubstream<S>::stream_id
pub fn stream_id(&self) -> StreamId;Source line: 258.
runtime::substream::AuthenticatedSubstream<S>::connection_id
pub fn connection_id(&self) -> ConnectionId;Source line: 262.
runtime::substream::AuthenticatedSubstream<S>::protocol
pub fn protocol(&self) -> &ProtocolId;Source line: 266.
runtime::substream::AuthenticatedSubstream<S>::local_peer_id
pub fn local_peer_id(&self) -> &CanonicalTransportPeerId;Source line: 270.
runtime::substream::AuthenticatedSubstream<S>::remote_peer_id
pub fn remote_peer_id(&self) -> &CanonicalTransportPeerId;Source line: 274.
runtime::substream::AuthenticatedSubstream<S>::role_ordered_peer_ids
pub fn role_ordered_peer_ids(&self) -> RoleOrderedTransportPeerIds;Source line: 278.
runtime::substream::AuthenticatedSubstream<S>::into_secure_transport
Consume this non-forgeable outer substream into T-B's authenticated transport capability.
pub fn into_secure_transport(
self,
) -> Result<zer0_secret_stream::session::AuthenticatedTransport<Self>, RuntimeError>;Source line: 293.