pub trait NextTarget: RailwayObject {
// Required methods
fn next_target(&self) -> Option<NodeId>;
fn set_next_target(&mut self, target: Option<NodeId>);
}
Expand description
The NextTarget
trait provides methods for managing a single target for a railway object.
Required Methods§
sourcefn next_target(&self) -> Option<NodeId>
fn next_target(&self) -> Option<NodeId>
Returns the next target of the railway object, if any.
sourcefn set_next_target(&mut self, target: Option<NodeId>)
fn set_next_target(&mut self, target: Option<NodeId>)
Sets the next target of the railway object.
Implementors§
impl NextTarget for Train
Implements the NextTarget
trait for the Train
struct.