pub struct Gateway {
pub mac_addr: MacAddr6,
pub router: MacAddr6,
pub outgoing_if: String,
pub bandwidth_down: Option<u32>,
pub bandwidth_up: Option<u32>,
pub throughput: Option<u32>,
pub tq: Option<u8>,
pub is_best: bool,
}Expand description
Represents a gateway in the batman-adv mesh.
This struct contains information about a gateway node, including its MAC address, the router it is associated with, interface used, bandwidth, throughput, and quality metrics.
Fields§
§mac_addr: MacAddr6MAC address of the gateway (BATADV_ATTR_ORIG_ADDRESS).
router: MacAddr6MAC address of the associated router (BATADV_ATTR_ROUTER).
outgoing_if: StringOutgoing interface used to reach this gateway. Usually from BATADV_ATTR_HARD_IFNAME; if not available, falls back to interface index.
bandwidth_down: Option<u32>Optional downstream bandwidth in kbps (BATADV_ATTR_BANDWIDTH_DOWN).
bandwidth_up: Option<u32>Optional upstream bandwidth in kbps (BATADV_ATTR_BANDWIDTH_UP).
throughput: Option<u32>Optional throughput in kbps (BATADV_ATTR_THROUGHPUT).
tq: Option<u8>Optional transmission quality (TQ) of the gateway (BATADV_ATTR_TQ).
is_best: boolWhether this gateway is considered the best among alternatives (BATADV_ATTR_FLAG_BEST).