Struct Sensor

pub struct Sensor {
    pub cot: CursorOnTarget,
    /* private fields */
}
Expand description

Sensor object

  • uid - Unique identifier
  • video_uid - Video unique identifier
  • parent_callsign - Parent callsign
  • callsign - Callsign
  • point - Point
  • fov - Field of view
  • fov_blue - Field of view blue
  • display_magnetic_reference - Display magnetic reference
  • range - Range
  • fov_green - Field of view green
  • fov_alpha - Field of view alpha
  • hide_fov - Hide field of view
  • fov_red - Field of view red
  • azimuth - Azimuth
  • config - Configuration

Fields§

§cot: CursorOnTarget

Implementations§

§

impl Sensor

pub fn new( cot: CursorOnTarget, uid: String, video_uid: String, parent_callsign: String, callsign: String, fov: f64, fov_blue: f64, display_magnetic_reference: f64, range: f64, fov_green: f64, fov_alpha: f64, hide_fov: bool, fov_red: f64, azimuth: i32, ) -> Self

pub fn get_xml(&mut self) -> String

Get XML text

§Returns
  • String - XML text
§Example
let xml = sensor.get_xml();

pub fn get_xml_bytes(&mut self) -> Vec<u8>

Get XML encoded bytes

§Returns
  • Vec<u8> - XML encoded bytes
§Example
let xml = sensor.get_xml_bytes();

Trait Implementations§

§

impl Debug for Sensor

§

fn fmt(&self, f: &mut Formatter<'_>) -> FmtResult

Formats the value using the given formatter. Read more
§

impl Sendable for Sensor

§

fn update_xml(&mut self)

§

fn modify_field(&mut self, field: &str, value: &str)

§

fn get_cot(&self) -> CursorOnTarget

Auto Trait Implementations§

§

impl Freeze for Sensor

§

impl RefUnwindSafe for Sensor

§

impl Send for Sensor

§

impl Sync for Sensor

§

impl Unpin for Sensor

§

impl UnwindSafe for Sensor

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.