pub struct Endpoint {
pub transport: TransportTag,
pub address: String,
}Expand description
Identifies where a consumer should connect to read a feed.
address is interpreted in a transport-specific way:
Tcp,Quic-"host:port"WebSocket,WebTransport- full URL, e.g."wss://host:port/path"Uds- filesystem pathStdio- empty
Fields§
§transport: TransportTag§address: StringImplementations§
Source§impl Endpoint
impl Endpoint
pub fn new(transport: TransportTag, address: impl Into<String>) -> Self
pub fn tcp(address: impl Into<String>) -> Self
pub fn websocket(url: impl Into<String>) -> Self
pub fn quic(address: impl Into<String>) -> Self
pub fn uds(path: impl Into<String>) -> Self
pub fn webtransport(url: impl Into<String>) -> Self
pub fn stdio() -> Self
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Endpoint
impl<'de> Deserialize<'de> for Endpoint
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
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