pub enum Endpoint {
Ws {
host: String,
port: u16,
secure: bool,
},
Http {
host: String,
port: u16,
secure: bool,
},
Unix {
path: PathBuf,
},
}Expand description
Parsed endpoint. Round-trip-safe: any input that parses also formats
back to the canonical string with [Endpoint::as_str].
Variants§
Implementations§
Source§impl Endpoint
impl Endpoint
pub fn parse(input: &str) -> Result<Self, Error>
Sourcepub fn http_base(&self) -> String
pub fn http_base(&self) -> String
HTTP base URL for /health, /capabilities, takeover panel. WS endpoints
derive an HTTP twin on the same host:port; Unix endpoints derive
http://unix-socket and use a unix transport at request time.
Sourcepub fn cdp_ws_url(&self) -> String
pub fn cdp_ws_url(&self) -> String
WS URL with path /cdp appended; the host routes that to the CDP
proxy.
Trait Implementations§
impl Eq for Endpoint
impl StructuralPartialEq for Endpoint
Auto Trait Implementations§
impl Freeze for Endpoint
impl RefUnwindSafe for Endpoint
impl Send for Endpoint
impl Sync for Endpoint
impl Unpin for Endpoint
impl UnsafeUnpin for Endpoint
impl UnwindSafe for Endpoint
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.