pub struct NodeID(pub [u8; 32], pub [u8; 3]);Expand description
The ID of a node in the network. The ID is 35 bytes long, the first 32 bytes are the node’s ed25519 public key, and the following 2 bytes are checksums, the last byte is the version number (1)
Tuple Fields§
§0: [u8; 32]§1: [u8; 3]Implementations§
Trait Implementations§
Source§impl<'de> Deserialize<'de> for NodeID
impl<'de> Deserialize<'de> for NodeID
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 Copy for NodeID
impl Eq for NodeID
impl StructuralPartialEq for NodeID
Auto Trait Implementations§
impl Freeze for NodeID
impl RefUnwindSafe for NodeID
impl Send for NodeID
impl Sync for NodeID
impl Unpin for NodeID
impl UnwindSafe for NodeID
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,
§impl<T> Deserialize<'_, u64> for T
impl<T> Deserialize<'_, u64> for T
§fn deserialize(de: Deserializer<'_>) -> Result<T, DeserializeError>
fn deserialize(de: Deserializer<'_>) -> Result<T, DeserializeError>
Deserializes value provided deserializer.
Returns deserialized value and the number of bytes consumed from
the and of input. Read more
§fn deserialize_in_place(
&mut self,
de: Deserializer<'_>,
) -> Result<(), DeserializeError>
fn deserialize_in_place( &mut self, de: Deserializer<'_>, ) -> Result<(), DeserializeError>
Deserializes value in-place provided deserializer.
Overwrites
self with data from the input. Read more§impl<'de, F, T> Deserialize<'de, As<F>> for Twhere
F: BareFormula + ?Sized,
T: Deserialize<'de, F>,
impl<'de, F, T> Deserialize<'de, As<F>> for Twhere
F: BareFormula + ?Sized,
T: Deserialize<'de, F>,
§fn deserialize(deserializer: Deserializer<'de>) -> Result<T, DeserializeError>
fn deserialize(deserializer: Deserializer<'de>) -> Result<T, DeserializeError>
Deserializes value provided deserializer.
Returns deserialized value and the number of bytes consumed from
the and of input. Read more
§fn deserialize_in_place(
&mut self,
deserializer: Deserializer<'de>,
) -> Result<(), DeserializeError>
fn deserialize_in_place( &mut self, deserializer: Deserializer<'de>, ) -> Result<(), DeserializeError>
Deserializes value in-place provided deserializer.
Overwrites
self with data from the input. Read more§impl<'de, T> Deserialize<'de, Bincode> for Twhere
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de, Bincode> for Twhere
T: Deserialize<'de>,
§fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
Deserializes value provided deserializer.
Returns deserialized value and the number of bytes consumed from
the and of input. Read more
§fn deserialize_in_place(
&mut self,
de: Deserializer<'de>,
) -> Result<(), DeserializeError>
fn deserialize_in_place( &mut self, de: Deserializer<'de>, ) -> Result<(), DeserializeError>
Deserializes value in-place provided deserializer.
Overwrites
self with data from the input. Read more§impl<'de, T> Deserialize<'de, Bincoded<T>> for Twhere
T: Deserialize<'de>,
impl<'de, T> Deserialize<'de, Bincoded<T>> for Twhere
T: Deserialize<'de>,
§fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
Deserializes value provided deserializer.
Returns deserialized value and the number of bytes consumed from
the and of input. Read more
§fn deserialize_in_place(
&mut self,
de: Deserializer<'de>,
) -> Result<(), DeserializeError>
fn deserialize_in_place( &mut self, de: Deserializer<'de>, ) -> Result<(), DeserializeError>
Deserializes value in-place provided deserializer.
Overwrites
self with data from the input. Read more§impl<'de, F, T> Deserialize<'de, Ref<F>> for T
impl<'de, F, T> Deserialize<'de, Ref<F>> for T
§fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
fn deserialize(de: Deserializer<'de>) -> Result<T, DeserializeError>
Deserializes value provided deserializer.
Returns deserialized value and the number of bytes consumed from
the and of input. Read more
§fn deserialize_in_place(
&mut self,
de: Deserializer<'de>,
) -> Result<(), DeserializeError>
fn deserialize_in_place( &mut self, de: Deserializer<'de>, ) -> Result<(), DeserializeError>
Deserializes value in-place provided deserializer.
Overwrites
self with data from the input. Read more§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.§impl<F, T> Serialize<As<F>> for Twhere
F: BareFormula + ?Sized,
T: Serialize<F>,
impl<F, T> Serialize<As<F>> for Twhere
F: BareFormula + ?Sized,
T: Serialize<F>,
§impl<T> Serialize<Bincode> for Twhere
T: Serialize,
impl<T> Serialize<Bincode> for Twhere
T: Serialize,
§impl<T> Serialize<Bincoded<T>> for Twhere
T: Serialize,
impl<T> Serialize<Bincoded<T>> for Twhere
T: Serialize,
§impl<F, T> Serialize<Ref<F>> for Twhere
F: BareFormula + ?Sized,
T: Serialize<F>,
impl<F, T> Serialize<Ref<F>> for Twhere
F: BareFormula + ?Sized,
T: Serialize<F>,
§impl<T> ToHex for T
impl<T> ToHex for T
§fn encode_hex<U>(&self) -> Uwhere
U: FromIterator<char>,
fn encode_hex<U>(&self) -> Uwhere
U: FromIterator<char>,
👎Deprecated: use
ToHexExt insteadEncode the hex strict representing
self into the result.
Lower case letters are used (e.g. f9b4ca).§fn encode_hex_upper<U>(&self) -> Uwhere
U: FromIterator<char>,
fn encode_hex_upper<U>(&self) -> Uwhere
U: FromIterator<char>,
👎Deprecated: use
ToHexExt insteadEncode the hex strict representing
self into the result.
Upper case letters are used (e.g. F9B4CA).§impl<T> ToHexExt for T
impl<T> ToHexExt for T
§fn encode_hex(&self) -> String
fn encode_hex(&self) -> String
Encode the hex strict representing
self into the result.
Lower case letters are used (e.g. f9b4ca).§fn encode_hex_upper(&self) -> String
fn encode_hex_upper(&self) -> String
Encode the hex strict representing
self into the result.
Upper case letters are used (e.g. F9B4CA).§fn encode_hex_with_prefix(&self) -> String
fn encode_hex_with_prefix(&self) -> String
Encode the hex strict representing
self into the result with prefix 0x.
Lower case letters are used (e.g. 0xf9b4ca).§fn encode_hex_upper_with_prefix(&self) -> String
fn encode_hex_upper_with_prefix(&self) -> String
Encode the hex strict representing
self into the result with prefix 0X.
Upper case letters are used (e.g. 0xF9B4CA).