Struct fxbox_taxonomy::devices::Get [] [src]

pub struct Get {
    pub kind: ChannelKind,
    pub poll: Option<ValDuration>,
    pub trigger: Option<ValDuration>,
    pub updated: Option<TimeStamp>,
    // some fields omitted
}

An input operation available on an service.

Fields

kind

The kind of value that can be obtained from this service.

poll

If Some(duration), this service can be polled, i.e. it will respond when the FoxBox requests the latest value. Parameter duration indicates the smallest interval between two updates.

Otherwise, the service cannot be polled and will push data to the FoxBox when it is available.

Examples

  • Long-running pollution or humidity sensors typically do not accept requests and rather send batches of data every 24h.
trigger

If Some(duration), this service can send the data to the FoxBox whenever it is updated. Parameter duration indicates the smallest interval between two updates.

Otherwise, the service cannot send data to the FoxBox and needs to be polled.

updated

Date at which the latest value was received, whether through polling or through a trigger.

Trait Implementations

impl Deserialize for Get

fn deserialize<__D>(deserializer: &mut __D) -> Result<Get, __D::Error> where __D: Deserializer

impl Serialize for Get

fn serialize<__S>(&self, serializer: &mut __S) -> Result<(), __S::Error> where __S: Serializer

impl IOMechanism for Get

Derived Implementations

impl Clone for Get

fn clone(&self) -> Get

1.0.0fn clone_from(&mut self, source: &Self)

impl Debug for Get

fn fmt(&self, __arg_0: &mut Formatter) -> Result