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§

source

fn next_target(&self) -> Option<NodeId>

Returns the next target of the railway object, if any.

source

fn set_next_target(&mut self, target: Option<NodeId>)

Sets the next target of the railway object.

Implementors§

source§

impl NextTarget for Train

Implements the NextTarget trait for the Train struct.