pub struct DocTicket {
pub capability: Capability,
pub nodes: Vec<EndpointAddr>,
}Expand description
Contains both a key (either secret or public) to a document, and a list of peers to join.
Fields§
§capability: Capabilityeither a public or private key
nodes: Vec<EndpointAddr>A list of nodes to contact.
Implementations§
Source§impl DocTicket
impl DocTicket
Sourcepub fn new(capability: Capability, peers: Vec<EndpointAddr>) -> Self
pub fn new(capability: Capability, peers: Vec<EndpointAddr>) -> Self
Create a new doc ticket
Trait Implementations§
Source§impl<'de> Deserialize<'de> for DocTicket
impl<'de> Deserialize<'de> for DocTicket
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 Ticket for DocTicket
impl Ticket for DocTicket
Source§fn from_bytes(bytes: &[u8]) -> Result<Self, ParseError>
fn from_bytes(bytes: &[u8]) -> Result<Self, ParseError>
Deserialize from the base32 string representation bytes.
Source§fn deserialize(str: &str) -> Result<Self, ParseError>
fn deserialize(str: &str) -> Result<Self, ParseError>
Deserialize from a string.
Auto Trait Implementations§
impl Freeze for DocTicket
impl RefUnwindSafe for DocTicket
impl Send for DocTicket
impl Sync for DocTicket
impl Unpin for DocTicket
impl UnsafeUnpin for DocTicket
impl UnwindSafe for DocTicket
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.