pub trait Target:
Clone
+ Debug
+ Eq
+ 'static {
// Required methods
fn render_self_into(&self, path: &mut Vec<String>);
fn render_path_into(&self, path: &mut Vec<String>);
fn parse_path(path: &[&str]) -> Option<Self>;
// Provided methods
fn render_self(&self) -> Vec<String> { ... }
fn render_path(&self) -> Vec<String> { ... }
}
Expand description
A target for used by a router.
Required Methods§
Sourcefn render_self_into(&self, path: &mut Vec<String>)
fn render_self_into(&self, path: &mut Vec<String>)
Render only our own path component.
Sourcefn render_path_into(&self, path: &mut Vec<String>)
fn render_path_into(&self, path: &mut Vec<String>)
Render the full path downwards.
Sourcefn parse_path(path: &[&str]) -> Option<Self>
fn parse_path(path: &[&str]) -> Option<Self>
Parse the target from the provided (segmented) path.
The path will be the local path, with the prefix already removed.
Provided Methods§
Sourcefn render_self(&self) -> Vec<String>
fn render_self(&self) -> Vec<String>
Render only our path segment.
Sourcefn render_path(&self) -> Vec<String>
fn render_path(&self) -> Vec<String>
Render the full path, including our children.
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.