Skip to main content

bacnet_transport/
lib.rs

1#![doc = include_str!("../README.md")]
2#![cfg_attr(docsrs, feature(doc_cfg))]
3// Redundant with the workspace lint, but explicit: only `sys` may allow it
4// (#1923).
5#![deny(unsafe_code)]
6
7/// Items for the targets whose libc has `getifaddrs`: the one walk over it
8/// (`sys::ifaddrs`, #1884) and its callers.
9macro_rules! with_getifaddrs {
10    ($($item:item)*) => {
11        $(
12            #[cfg(any(
13                target_os = "linux",
14                target_os = "l4re",
15                target_os = "android",
16                target_os = "emscripten",
17                target_vendor = "apple",
18                target_os = "freebsd",
19                target_os = "dragonfly",
20                target_os = "openbsd",
21                target_os = "netbsd",
22                target_os = "solaris",
23                target_os = "illumos",
24                target_os = "haiku",
25                target_os = "nto",
26                target_os = "hurd",
27                target_os = "fuchsia",
28            ))]
29            $item
30        )*
31    };
32}
33
34/// Items for the targets with no interface list: neither `getifaddrs` nor
35/// Windows.
36macro_rules! without_interface_list {
37    ($($item:item)*) => {
38        $(
39            #[cfg(not(any(
40                windows,
41                target_os = "linux",
42                target_os = "l4re",
43                target_os = "android",
44                target_os = "emscripten",
45                target_vendor = "apple",
46                target_os = "freebsd",
47                target_os = "dragonfly",
48                target_os = "openbsd",
49                target_os = "netbsd",
50                target_os = "solaris",
51                target_os = "illumos",
52                target_os = "haiku",
53                target_os = "nto",
54                target_os = "hurd",
55                target_os = "fuchsia",
56            )))]
57            $item
58        )*
59    };
60}
61
62pub mod any;
63pub mod bbmd;
64pub mod bip;
65#[cfg(feature = "ipv6")]
66#[cfg_attr(docsrs, doc(cfg(feature = "ipv6")))]
67pub mod bip6;
68pub mod bvll;
69mod direct_response;
70#[cfg(feature = "ethernet")]
71#[cfg_attr(docsrs, doc(cfg(feature = "ethernet")))]
72pub mod ethernet;
73mod local_addresses;
74pub mod loopback;
75pub mod mstp;
76#[cfg(feature = "serial")]
77#[cfg_attr(docsrs, doc(cfg(feature = "serial")))]
78pub mod mstp_serial;
79mod npdu_channel;
80pub mod port;
81mod port_ownership;
82mod principal;
83mod runtime_clock;
84pub mod sc;
85pub mod sc_frame;
86#[cfg(feature = "sc-tls")]
87#[cfg_attr(docsrs, doc(cfg(feature = "sc-tls")))]
88pub mod sc_hub;
89mod sc_limits;
90#[cfg(feature = "sc-tls")]
91#[cfg_attr(docsrs, doc(cfg(feature = "sc-tls")))]
92pub mod sc_tls;
93mod sys;
94pub mod tap;
95#[cfg(feature = "sc-tls")]
96mod tcp_connect;
97#[cfg(feature = "sc-tls")]
98mod tls_reject;
99mod udp_metadata;
100pub mod warn_throttle;
101
102#[cfg(test)]
103mod log_capture;
104#[cfg(test)]
105#[path = "rb07_provenance_tests.rs"]
106mod rb07_provenance_tests;