pub struct PingResult {
pub ip: IpAddr,
pub rtt_ms: Option<u64>,
pub ttl: Option<u8>,
pub alive: bool,
pub seq: u16,
pub error: Option<String>,
pub method: Option<String>,
}Fields§
§ip: IpAddr§rtt_ms: Option<u64>§ttl: Option<u8>The reply’s IP time-to-live, where the platform exposes it: Windows’
ICMP API does, the raw-socket path on Unix strips the IP header before
the reply is parsed, and the TCP fallback has no reply packet at all.
A starting TTL of 64, 128 or 255 hints at the OS family; see
os_hint.
alive: bool§seq: u16Sequence number actually used for this ping (monotonic per process). Useful for debugging concurrent scans against logging-enabled targets.
error: Option<String>§method: Option<String>Indicates which mechanism was used (e.g., icmpv4, tcp-connect).
Trait Implementations§
Source§impl Clone for PingResult
impl Clone for PingResult
Source§impl Debug for PingResult
impl Debug for PingResult
Auto Trait Implementations§
impl Freeze for PingResult
impl RefUnwindSafe for PingResult
impl Send for PingResult
impl Sync for PingResult
impl Unpin for PingResult
impl UnsafeUnpin for PingResult
impl UnwindSafe for PingResult
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,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
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