[−][src]Enum lib3h_protocol::protocol_server::Lib3hServerProtocol
Enum holding all message types in the 'hc-core <- P2P network module' protocol. There are 4 categories of messages:
- Command: An order from the local node to the p2p module. Local node expects a reponse. Starts with a verb.
- Handle-command: An order from the p2p module to the local node. The p2p module expects a response. Start withs 'Handle' followed by a verb.
- Result: A response to a Command. Starts with the name of the Command it responds to and ends with 'Result'.
- Notification: Notify that something happened. Not expecting any response. Ends with verb in past form, i.e. '-ed'. Fetch = Request between node and the network (other nodes) Get = Request within a node between p2p module and core
Variants
SuccessResult(GenericResultData)
Success response to a request (any Command with an request_id
field.)
FailureResult(GenericResultData)
Failure response to a request (any Command with an request_id
field.)
Can also be a response to a mal-formed request.
Connected(ConnectedData)
Notification of successful connection to a network
Disconnected(DisconnectedData)
Notification of disconnection from a network
SendDirectMessageResult(DirectMessageData)
the response received from a previous SendDirectMessage
HandleSendDirectMessage(DirectMessageData)
Request to handle a direct message another agent has sent us.
FetchEntryResult(FetchEntryResultData)
Response from requesting dht data from the network
HandleFetchEntry(FetchEntryData)
Another node, or the network module itself is requesting data from us
HandleStoreEntryAspect(StoreEntryAspectData)
Store data on a node's dht arc.
HandleDropEntry(DropEntryData)
Local client does not need to hold that entry anymore. Local client doesn't 'have to' comply.
HandleQueryEntry(QueryEntryData)
Request a node to handle a QueryEntry request
QueryEntryResult(QueryEntryResultData)
Response to a QueryEntry
request
HandleGetAuthoringEntryList(GetListData)
HandleGetGossipingEntryList(GetListData)
Trait Implementations
impl From<Lib3hServerProtocol> for ClientToLib3hResponse
[src]
fn from(c: Lib3hServerProtocol) -> Self
[src]
impl From<Lib3hToClient> for Lib3hServerProtocol
[src]
fn from(c: Lib3hToClient) -> Self
[src]
impl From<ClientToLib3hResponse> for Lib3hServerProtocol
[src]
fn from(c: ClientToLib3hResponse) -> Self
[src]
impl Clone for Lib3hServerProtocol
[src]
fn clone(&self) -> Lib3hServerProtocol
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl PartialEq<Lib3hServerProtocol> for Lib3hServerProtocol
[src]
fn eq(&self, other: &Lib3hServerProtocol) -> bool
[src]
fn ne(&self, other: &Lib3hServerProtocol) -> bool
[src]
impl Debug for Lib3hServerProtocol
[src]
impl TryFrom<Lib3hServerProtocol> for Lib3hToClient
[src]
type Error = Lib3hProtocolError
The type returned in the event of a conversion error.
fn try_from(c: Lib3hServerProtocol) -> Result<Self, Self::Error>
[src]
impl StructuralPartialEq for Lib3hServerProtocol
[src]
impl Serialize for Lib3hServerProtocol
[src]
fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error> where
__S: Serializer,
[src]
__S: Serializer,
impl<'de> Deserialize<'de> for Lib3hServerProtocol
[src]
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
[src]
__D: Deserializer<'de>,
Auto Trait Implementations
impl Send for Lib3hServerProtocol
impl Sync for Lib3hServerProtocol
impl Unpin for Lib3hServerProtocol
impl UnwindSafe for Lib3hServerProtocol
impl RefUnwindSafe for Lib3hServerProtocol
Blanket Implementations
impl<T> From<T> for T
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = !
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Clone for T where
T: Clone,
[src]
T: Clone,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> DeserializeOwned for T where
T: Deserialize<'de>,
[src]
T: Deserialize<'de>,
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,