pub enum Address {
Ground {
station: u8,
},
Satellite(Point),
ServiceArea {
orb: u8,
},
}Expand description
A logical address in the ISL network.
Variants§
Ground
A ground station identified by its station number.
Satellite(Point)
A specific satellite at a grid position.
ServiceArea
All satellites in a given orbital plane (multicast).
Implementations§
Source§impl Address
impl Address
Sourcepub fn satellite(orb: u8, sat: u8) -> Self
pub fn satellite(orb: u8, sat: u8) -> Self
Creates a satellite address from orbital plane and satellite indices.
Sourcepub fn service_area(orb: u8) -> Self
pub fn service_area(orb: u8) -> Self
Creates a service area (multicast) address for an orbital plane.
Sourcepub fn is_valid_source(&self) -> bool
pub fn is_valid_source(&self) -> bool
Returns true if this address can be used as a packet source.
Sourcepub fn is_in_service_area(&self, min_sat: u8, max_sat: u8) -> bool
pub fn is_in_service_area(&self, min_sat: u8, max_sat: u8) -> bool
Returns true if this satellite falls within the given service area range.
Trait Implementations§
Source§impl From<Address> for RawAddress
impl From<Address> for RawAddress
impl Copy for Address
impl Eq for Address
impl StructuralPartialEq for Address
Auto Trait Implementations§
impl Freeze for Address
impl RefUnwindSafe for Address
impl Send for Address
impl Sync for Address
impl Unpin for Address
impl UnsafeUnpin for Address
impl UnwindSafe for Address
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