pub struct TransportSpec { /* private fields */ }Expand description
A transport named at an adapter boundary.
Implementations§
Source§impl TransportSpec
impl TransportSpec
Sourcepub fn new(
kind: TransportKind,
target: impl Into<Arc<str>>,
) -> Result<Self, SpecError>
pub fn new( kind: TransportKind, target: impl Into<Arc<str>>, ) -> Result<Self, SpecError>
A spec for kind pointed at target.
§Errors
SpecError::EmptyTarget when target is empty. A spec with no
target is a spec that cannot be acted on, and letting it exist means
the failure surfaces later as a connection to nothing.
Sourcepub const fn kind(&self) -> TransportKind
pub const fn kind(&self) -> TransportKind
The transport named.
Trait Implementations§
Source§impl Clone for TransportSpec
impl Clone for TransportSpec
Source§impl Debug for TransportSpec
impl Debug for TransportSpec
Source§impl Display for TransportSpec
impl Display for TransportSpec
impl Eq for TransportSpec
Source§impl FromStr for TransportSpec
impl FromStr for TransportSpec
Source§impl PartialEq for TransportSpec
impl PartialEq for TransportSpec
impl StructuralPartialEq for TransportSpec
Auto Trait Implementations§
impl Freeze for TransportSpec
impl RefUnwindSafe for TransportSpec
impl Send for TransportSpec
impl Sync for TransportSpec
impl Unpin for TransportSpec
impl UnsafeUnpin for TransportSpec
impl UnwindSafe for TransportSpec
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