pub fn was_connection_recently_attempted(&self, now: Instant) -> bool {
        if let Some(last_attempt) = self.last_attempt {
            // Recent times and future times are considered live.
            // Instants are monotonic, so `now` should always be later than `last_attempt`,
            // except for synthetic data in tests.
            now.saturating_duration_since(last_attempt) <= constants::MIN_PEER_RECONNECTION_DELAY
        } else {
            // If there has never been any attempt, it can't possibly be live
            false
        }
    }
/// Have we recently attempted an outbound connection to this peer?
///
/// Returns `true` if this peer was recently attempted, or has a connection
/// attempt in progress.
Have we recently attempted an outbound connection to this peer.
Returns `true` if this peer was recently attempted, or has a connection
attempt in progress.
Have we recently attempted an outbound connection to this peer . Returns ` true ` if this peer was recently attempted or has a connection attempt in progress .
pub fn was_connection_recently_attempted(&self, now: Instant) -> bool {
        if let Some(last_attempt) = self.last_attempt {
            // Recent times and future times are considered live.
            // Instants are monotonic, so `now` should always be later than `last_attempt`,
            // except for synthetic data in tests.
            now.saturating_duration_since(last_attempt) <= constants::MIN_PEER_RECONNECTION_DELAY
        } else {
            // If there has never been any attempt, it can't possibly be live
            false
        }
    }
pub fn was_connection_recently_attempted ( & self , now : Instant ) -> bool { if let Some ( last_attempt ) = self . last_attempt { // Recent times and future times are considered live. // Instants are monotonic, so `now` should always be later than `last_attempt`, // except for synthetic data in tests. now . saturating_duration_since ( last_attempt ) <= constants :: MIN_PEER_RECONNECTION_DELAY } else { // If there has never been any attempt, it can't possibly be live false } }
Have we recently attempted an outbound connection to this peer?
Have we recently attempted an outbound connection to this peer?
&self
now
Instant