pub enum BrowserResponseBody {
ChunkProtocol,
Hello {
protocol: String,
peer_id: String,
max_chunk_size: usize,
endpoint: BrowserEndpoint,
payment: BrowserPaymentNetwork,
capabilities: Vec<String>,
},
Nodes {
target: String,
nodes: Vec<BrowserNode>,
},
Chunk {
address: String,
size: usize,
},
ChunkNotFound {
address: String,
},
StorageQuote {
address: String,
already_stored: bool,
quote: BrowserQuoteArtifact,
},
ChunkStored {
address: String,
already_stored: bool,
},
Error {
code: String,
message: String,
},
}Expand description
Browser RPC response variants and their fields.
Variants§
ChunkProtocol
An encoded ant-protocol response in the binary body.
Hello
Authenticated node and protocol metadata.
Fields
§
endpoint: BrowserEndpointEndpoint authenticated by the session.
§
payment: BrowserPaymentNetworkPublic payment configuration.
Nodes
Closest-node lookup result.
Fields
§
nodes: Vec<BrowserNode>Closest known nodes.
Chunk
Immutable record metadata; bytes follow the header.
ChunkNotFound
Missing immutable record metadata.
StorageQuote
Signed quote for storing an immutable record.
Fields
§
quote: BrowserQuoteArtifactSigned quote and optional commitment.
ChunkStored
Confirmation that an immutable record was stored.
Fields
Error
Stable error code and human-readable detail.
Trait Implementations§
Source§impl Clone for BrowserResponseBody
impl Clone for BrowserResponseBody
Source§fn clone(&self) -> BrowserResponseBody
fn clone(&self) -> BrowserResponseBody
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for BrowserResponseBody
impl Debug for BrowserResponseBody
Source§impl<'de> Deserialize<'de> for BrowserResponseBody
impl<'de> Deserialize<'de> for BrowserResponseBody
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<BrowserResponseBody, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<BrowserResponseBody, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl PartialEq for BrowserResponseBody
impl PartialEq for BrowserResponseBody
Source§impl Serialize for BrowserResponseBody
impl Serialize for BrowserResponseBody
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl StructuralPartialEq for BrowserResponseBody
Auto Trait Implementations§
impl Freeze for BrowserResponseBody
impl RefUnwindSafe for BrowserResponseBody
impl Send for BrowserResponseBody
impl Sync for BrowserResponseBody
impl Unpin for BrowserResponseBody
impl UnsafeUnpin for BrowserResponseBody
impl UnwindSafe for BrowserResponseBody
Blanket Implementations§
impl<T> AdapterBounds for Twhere
T: Sync,
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<'de, T> BorrowedRpcObject<'de> for T
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,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
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> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more