opensensor 0.4.0

A crate for streaming and archiving measurements from sensors
1
2
3
4
5
6
7
8
9
10
11
12
13
/// Sensors should implement this trait for Apache Arrow in-memory serialization and deserialization
pub trait ArrowSerializable {
    /// This should be the error type of the implementing sensor
    type Error;

    /// Serialize this implementing sensor to bytes with Arrow IPC writer
    fn arrow_serialize(self) -> Vec<u8>;

    /// Static method to construct sensor type from bytes
    fn arrow_deserialize(bytes: &[u8]) -> Result<Self, Self::Error>
    where
        Self: Sized;
}