#[repr(C)]pub struct Meta {
pub size: usize,
pub addr: IpAddr,
pub port: u16,
pub flags: PacketFlags,
}
Fields§
§size: usize
§addr: IpAddr
§port: u16
§flags: PacketFlags
Implementations§
Source§impl Meta
impl Meta
pub fn socket_addr(&self) -> SocketAddr
pub fn set_socket_addr(&mut self, socket_addr: &SocketAddr)
pub fn set_from_staked_node(&mut self, from_staked_node: bool)
pub fn discard(&self) -> bool
pub fn set_discard(&mut self, discard: bool)
pub fn set_tracer(&mut self, is_tracer: bool)
pub fn set_track_performance(&mut self, is_performance_track: bool)
pub fn set_simple_vote(&mut self, is_simple_vote: bool)
pub fn forwarded(&self) -> bool
pub fn repair(&self) -> bool
pub fn is_simple_vote_tx(&self) -> bool
pub fn is_tracer_packet(&self) -> bool
pub fn is_perf_track_packet(&self) -> bool
pub fn is_from_staked_node(&self) -> bool
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Meta
impl<'de> Deserialize<'de> for Meta
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 Eq for Meta
impl StructuralPartialEq for Meta
Auto Trait Implementations§
impl Freeze for Meta
impl RefUnwindSafe for Meta
impl Send for Meta
impl Sync for Meta
impl Unpin for Meta
impl UnwindSafe for Meta
Blanket Implementations§
Source§impl<T> AbiEnumVisitor for T
impl<T> AbiEnumVisitor for T
default fn visit_for_abi( &self, _digester: &mut AbiDigester, ) -> Result<AbiDigester, DigestError>
Source§impl<T> AbiEnumVisitor for Twhere
T: Serialize + AbiExample,
impl<T> AbiEnumVisitor for Twhere
T: Serialize + AbiExample,
default fn visit_for_abi( &self, digester: &mut AbiDigester, ) -> Result<AbiDigester, DigestError>
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,
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