Skip to main content

decode_shed_level

Function decode_shed_level 

Source
pub fn decode_shed_level(
    data: &[u8],
    offset: usize,
) -> Result<(BACnetShedLevel, usize), Error>
Expand description

Decode one BACnetShedLevel CHOICE at offset.

Returns the value and the offset just past it; a caller holding exactly one value must check that offset reaches the end of its data. Any tag but a primitive context [0], [1] or [2], an Unsigned of no octets or more than eight, a REAL that isn’t four octets, or truncated contents fails with Error::Decoding or Error::BufferTooShort. The decoder checks structure only: what range each alternative may take is up to the object.