pub fn range(&self) -> ArcRange {
        if self.half_length == 0 {
            ArcRange {
                start: Bound::Excluded(self.center_loc.into()),
                end: Bound::Excluded(self.center_loc.into()),
            }
        } else if self.half_length == 1 {
            ArcRange {
                start: Bound::Included(self.center_loc.into()),
                end: Bound::Included(self.center_loc.into()),
            }
        } else if self.half_length == MAX_HALF_LENGTH {
            ArcRange {
                start: Bound::Included(
                    (self.center_loc.0 - DhtLocation::from(MAX_HALF_LENGTH - 1).0).0,
                ),
                end: Bound::Included(
                    (self.center_loc.0 + DhtLocation::from(MAX_HALF_LENGTH).0 - Wrapping(2)).0,
                ),
            }
        } else {
            ArcRange {
                start: Bound::Included(
                    (self.center_loc.0 - DhtLocation::from(self.half_length - 1).0).0,
                ),
                end: Bound::Included(
                    (self.center_loc.0 + DhtLocation::from(self.half_length).0 - Wrapping(1)).0,
                ),
            }
        }
    }
/// Get the range of the arc
Get the range of the arc
Get the range of the arc
pub fn range(&self) -> ArcRange {
        if self.half_length == 0 {
            ArcRange {
                start: Bound::Excluded(self.center_loc.into()),
                end: Bound::Excluded(self.center_loc.into()),
            }
        } else if self.half_length == 1 {
            ArcRange {
                start: Bound::Included(self.center_loc.into()),
                end: Bound::Included(self.center_loc.into()),
            }
        } else if self.half_length == MAX_HALF_LENGTH {
            ArcRange {
                start: Bound::Included(
                    (self.center_loc.0 - DhtLocation::from(MAX_HALF_LENGTH - 1).0).0,
                ),
                end: Bound::Included(
                    (self.center_loc.0 + DhtLocation::from(MAX_HALF_LENGTH).0 - Wrapping(2)).0,
                ),
            }
        } else {
            ArcRange {
                start: Bound::Included(
                    (self.center_loc.0 - DhtLocation::from(self.half_length - 1).0).0,
                ),
                end: Bound::Included(
                    (self.center_loc.0 + DhtLocation::from(self.half_length).0 - Wrapping(1)).0,
                ),
            }
        }
    }
pub fn range ( & self ) -> ArcRange { if self . half_length == 0 { ArcRange { start : Bound :: Excluded ( self . center_loc . into ( ) ) , end : Bound :: Excluded ( self . center_loc . into ( ) ) , } } else if self . half_length == 1 { ArcRange { start : Bound :: Included ( self . center_loc . into ( ) ) , end : Bound :: Included ( self . center_loc . into ( ) ) , } } else if self . half_length == MAX_HALF_LENGTH { ArcRange { start : Bound :: Included ( ( self . center_loc . 0 - DhtLocation :: from ( MAX_HALF_LENGTH - 1 ) . 0 ) . 0 , ) , end : Bound :: Included ( ( self . center_loc . 0 + DhtLocation :: from ( MAX_HALF_LENGTH ) . 0 - Wrapping ( 2 ) ) . 0 , ) , } } else { ArcRange { start : Bound :: Included ( ( self . center_loc . 0 - DhtLocation :: from ( self . half_length - 1 ) . 0 ) . 0 , ) , end : Bound :: Included ( ( self . center_loc . 0 + DhtLocation :: from ( self . half_length ) . 0 - Wrapping ( 1 ) ) . 0 , ) , } } }
Get the range of the arc
Get the range of the arc
&self
&self