pub struct ServerLabel(/* private fields */);Expand description
How one external server is named inside this city.
The label is the first segment of every tool that server offers
({label}_{tool}), so two servers that both offer search stay two
tools rather than becoming one that sometimes does the wrong thing.
Its grammar is ToolName’s minus the underscore: allowing one
would let apps_foo_bar be read as two different splits, and this
name routes a call.
It lives here rather than beside the protocol that uses it because the rule it enforces is a rule about tool names, and a rule written in two crates is a rule with two authorities.
Implementations§
Trait Implementations§
Source§impl Clone for ServerLabel
impl Clone for ServerLabel
Source§impl Debug for ServerLabel
impl Debug for ServerLabel
Source§impl<'de> Deserialize<'de> for ServerLabel
impl<'de> Deserialize<'de> for ServerLabel
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for ServerLabel
impl Display for ServerLabel
impl Eq for ServerLabel
Source§impl From<ServerLabel> for String
impl From<ServerLabel> for String
Source§fn from(label: ServerLabel) -> String
fn from(label: ServerLabel) -> String
Converts to this type from the input type.
Source§impl Ord for ServerLabel
impl Ord for ServerLabel
1.21.0 (const: unstable) · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
1.21.0 (const: unstable) · Source§fn min(self, other: Self) -> Selfwhere
Self: Sized,
fn min(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the minimum of two values. Read more
Source§impl PartialEq for ServerLabel
impl PartialEq for ServerLabel
Source§impl PartialOrd for ServerLabel
impl PartialOrd for ServerLabel
Source§impl Serialize for ServerLabel
impl Serialize for ServerLabel
impl StructuralPartialEq for ServerLabel
Auto Trait Implementations§
impl Freeze for ServerLabel
impl RefUnwindSafe for ServerLabel
impl Send for ServerLabel
impl Sync for ServerLabel
impl Unpin for ServerLabel
impl UnsafeUnpin for ServerLabel
impl UnwindSafe for ServerLabel
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