1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
//! Rust access library to read/write iChen® 4 Open Protocol™ messages.
//!
//! Details on the protocol can be found in [this document].
//!
//! Design Notes
//! ============
//!
//! Beware that all data types defined in this crate use borrowed string slices (i.e. `&str`) extensively.
//! This is because the most common usage pattern is to create a data variable, set fields, immediately
//! serialize it into JSON, then dispose of the data variable. The deserialization story is similar.
//!
//! Error values also borrow heavily from the input fields as these errors are expected to be handled
//! as soon as possible.
//!
//! The result is minimal allocations and copying, but at the cost of stricter lifetime management,
//! especially when deserializing -- the message struct cannot out-live the original JSON text string as
//! fields are borrowed extensively from the original JSON string.
//!
//! Another implication due to extensive usage of borrowed string slices is that string literals with
//! escape sequences will cause parsing errors because the actual string cannot be simply borrowed from
//! the original JSON string. Luckily this is extremely rare for most fields holding names, ID's etc.
//! For this reason, only certain user-defined text fields (such as `job_card_id`) may contain
//! escaped characters (especially the double-quote); those are therefore modeled using `Cow<&str>` instead.
//!
//! [this document]: https://github.com/chenhsong/OpenProtocol/blob/master/cs/doc/messages_reference.md
//!
// Modules
/// Result type.
pub type Result<'a, T> = Result;
/// Result error type.
pub type Error<'a> = ;
/// 32-bit real floating-point number.
pub use R32;
// Re-exports
pub use Address;
pub use Controller;
pub use OpenProtocolError;
pub use Filters;
pub use GeoLocation;
pub use JobCard;
pub use KeyValuePair;
pub use *;
pub use Operator;
pub use StateValues;
pub use ;
pub use ;