Struct sbp::messages::system::msg_group_meta::MsgGroupMeta
source · [−]pub struct MsgGroupMeta {
pub sender_id: Option<u16>,
pub group_id: u8,
pub flags: u8,
pub n_group_msgs: u8,
pub group_msgs: Vec<u16>,
}
Expand description
Solution Group Metadata
This leading message lists the time metadata of the Solution Group. It also lists the atomic contents (i.e. types of messages included) of the Solution Group.
Fields
sender_id: Option<u16>
The message sender_id
group_id: u8
Id of the Msgs Group, 0 is Unknown, 1 is Bestpos, 2 is Gnss
flags: u8
Status flags (reserved)
n_group_msgs: u8
Size of list group_msgs
group_msgs: Vec<u16>
An in-order list of message types included in the Solution Group, including GROUP_META itself
Implementations
sourceimpl MsgGroupMeta
impl MsgGroupMeta
sourcepub fn solution_group_type(&self) -> Result<SolutionGroupType, u8>
pub fn solution_group_type(&self) -> Result<SolutionGroupType, u8>
Gets the SolutionGroupType stored in the flags
bitfield.
Returns Ok
if the bitrange contains a known SolutionGroupType
variant.
Otherwise the value of the bitrange is returned as an Err(u8)
. This may be because of a malformed message,
or because new variants of SolutionGroupType
were added.
sourcepub fn set_solution_group_type(
&mut self,
solution_group_type: SolutionGroupType
)
pub fn set_solution_group_type(
&mut self,
solution_group_type: SolutionGroupType
)
Set the bitrange corresponding to the SolutionGroupType of the flags
bitfield.
Trait Implementations
sourceimpl Clone for MsgGroupMeta
impl Clone for MsgGroupMeta
sourcefn clone(&self) -> MsgGroupMeta
fn clone(&self) -> MsgGroupMeta
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl ConcreteMessage for MsgGroupMeta
impl ConcreteMessage for MsgGroupMeta
sourceconst MESSAGE_TYPE: u16
const MESSAGE_TYPE: u16
The message type.
sourceconst MESSAGE_NAME: &'static str
const MESSAGE_NAME: &'static str
The message name.
sourceimpl Debug for MsgGroupMeta
impl Debug for MsgGroupMeta
sourceimpl From<MsgGroupMeta> for Sbp
impl From<MsgGroupMeta> for Sbp
sourcefn from(msg: MsgGroupMeta) -> Self
fn from(msg: MsgGroupMeta) -> Self
Performs the conversion.
sourceimpl SbpMessage for MsgGroupMeta
impl SbpMessage for MsgGroupMeta
sourcefn message_name(&self) -> &'static str
fn message_name(&self) -> &'static str
Get the message name.
sourcefn message_type(&self) -> u16
fn message_type(&self) -> u16
Get the message type.
sourcefn set_sender_id(&mut self, new_id: u16)
fn set_sender_id(&mut self, new_id: u16)
Set the sender id.
sourcefn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Number of bytes this message will take on the wire.
Auto Trait Implementations
impl RefUnwindSafe for MsgGroupMeta
impl Send for MsgGroupMeta
impl Sync for MsgGroupMeta
impl Unpin for MsgGroupMeta
impl UnwindSafe for MsgGroupMeta
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcepub fn to_owned(&self) -> T
pub fn to_owned(&self) -> T
Creates owned data from borrowed data, usually by cloning. Read more
sourcepub fn clone_into(&self, target: &mut T)
pub fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more