pub struct TrafficSign<'a> {
pub traffic_sign: &'a TrafficSign,
}Expand description
Models a physical traffic sign — a static, passive signaling device placed along or above the road to convey regulatory, warning, or informational messages to road users.
Unlike TrafficLight, traffic signs do not expose phase-based bulb states. A sign may still be marked as dynamic or movable by backend metadata.
Fields§
§traffic_sign: &'a TrafficSignImplementations§
Source§impl<'a> TrafficSign<'a>
impl<'a> TrafficSign<'a>
Sourcepub fn sign_type(&self) -> TrafficSignType
pub fn sign_type(&self) -> TrafficSignType
Sourcepub fn position_road_network(&self) -> InertialPosition
pub fn position_road_network(&self) -> InertialPosition
Gets the position of the TrafficSign in the road network’s Inertial frame.
§Returns
An super::InertialPosition representing the position of the TrafficSign.
Sourcepub fn orientation_road_network(&self) -> Rotation
pub fn orientation_road_network(&self) -> Rotation
Gets the orientation of the TrafficSign in the road network’s Inertial frame.
§Returns
An super::Rotation representing the orientation of the TrafficSign.
Sourcepub fn message(&self) -> Option<String>
pub fn message(&self) -> Option<String>
Gets the optional text message displayed on the TrafficSign.
§Returns
Some(String) if a message is set, None otherwise.
Sourcepub fn is_dynamic(&self) -> bool
pub fn is_dynamic(&self) -> bool
Returns whether this sign can change semantically over time.
Sourcepub fn is_movable(&self) -> bool
pub fn is_movable(&self) -> bool
Returns whether this sign’s position can change.
Sourcepub fn bounding_box(&self) -> BoundingBox
pub fn bounding_box(&self) -> BoundingBox
Gets the bounding box of the TrafficSign.
§Returns
A crate::math::BoundingBox describing the sign’s oriented bounding volume.
The box position is the centroid, box_size gives full extents, and orientation
is expressed as roll-pitch-yaw angles.
Sourcepub fn value(&self) -> Option<TrafficSignValue>
pub fn value(&self) -> Option<TrafficSignValue>
Gets the optional numeric value associated with the TrafficSign.
§Returns
Some(TrafficSignValue) if a value is set, None otherwise.
Sourcepub fn properties(&self) -> HashMap<String, String>
pub fn properties(&self) -> HashMap<String, String>
Returns backend-specific key-value properties for this TrafficSign.
Sourcepub fn dependent_signs(&self) -> Vec<String>
pub fn dependent_signs(&self) -> Vec<String>
Returns the TrafficSigns’ IDs that depend on this sign, if any. For example, a “Stop” sign may have an associated “All way” sign.