Struct bip_dht::message::get_peers::GetPeersResponse
[−]
[src]
pub struct GetPeersResponse<'a> { /* fields omitted */ }
Methods
impl<'a> GetPeersResponse<'a>
[src]
fn new(
trans_id: &'a [u8],
node_id: NodeId,
token: Option<&'a [u8]>,
info_type: CompactInfoType<'a>
) -> GetPeersResponse<'a>
trans_id: &'a [u8],
node_id: NodeId,
token: Option<&'a [u8]>,
info_type: CompactInfoType<'a>
) -> GetPeersResponse<'a>
fn from_parts(
rsp_root: &'a Dictionary<'a, Bencode<'a>>,
trans_id: &'a [u8]
) -> Result<GetPeersResponse<'a>, DhtError>
rsp_root: &'a Dictionary<'a, Bencode<'a>>,
trans_id: &'a [u8]
) -> Result<GetPeersResponse<'a>, DhtError>
fn transaction_id(&self) -> &'a [u8]
fn node_id(&self) -> NodeId
fn token(&self) -> Option<&'a [u8]>
fn info_type(&self) -> CompactInfoType<'a>
fn encode(&self) -> Vec<u8>
Trait Implementations
impl<'a> Copy for GetPeersResponse<'a>
[src]
impl<'a> Clone for GetPeersResponse<'a>
[src]
fn clone(&self) -> GetPeersResponse<'a>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl<'a> PartialEq for GetPeersResponse<'a>
[src]
fn eq(&self, __arg_0: &GetPeersResponse<'a>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &GetPeersResponse<'a>) -> bool
This method tests for !=
.
impl<'a> Eq for GetPeersResponse<'a>
[src]
impl<'a> Hash for GetPeersResponse<'a>
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more