Struct chik_protocol::Handshake
source · pub struct Handshake {
pub network_id: String,
pub protocol_version: String,
pub software_version: String,
pub server_port: u16,
pub node_type: NodeType,
pub capabilities: Vec<(u16, String)>,
}Fields§
§network_id: String§protocol_version: String§software_version: String§server_port: u16§node_type: NodeType§capabilities: Vec<(u16, String)>Implementations§
Trait Implementations§
source§impl ChikProtocolMessage for Handshake
impl ChikProtocolMessage for Handshake
fn msg_type() -> ProtocolMessageTypes
source§impl PartialEq for Handshake
impl PartialEq for Handshake
source§impl Streamable for Handshake
impl Streamable for Handshake
fn update_digest(&self, digest: &mut Sha256)
fn stream(&self, out: &mut Vec<u8>) -> Result<()>
fn parse<const TRUSTED: bool>(input: &mut Cursor<&[u8]>) -> Result<Self>
fn to_bytes(&self) -> Result<Vec<u8>, Error>
fn from_bytes(bytes: &[u8]) -> Result<Self, Error>where
Self: Sized,
fn from_bytes_unchecked(bytes: &[u8]) -> Result<Self, Error>where
Self: Sized,
fn hash(&self) -> [u8; 32]
impl Eq for Handshake
impl StructuralPartialEq for Handshake
Auto Trait Implementations§
impl Freeze for Handshake
impl RefUnwindSafe for Handshake
impl Send for Handshake
impl Sync for Handshake
impl Unpin for Handshake
impl UnwindSafe for Handshake
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