Enum rocket_http::uri::Path
source · [−]pub enum Path {}
Expand description
Marker type indicating use of a type for the path UriPart
of a URI.
In route URIs, this corresponds to all of the text before a ?
, if any, or
all of the text in the URI otherwise:
#[get("/home/<name>/<page>?<item>")]
^------------------ Path
Trait Implementations
sourceimpl<'a, 'b> FromUriParam<Path, &'a &'b str> for PathBuf
impl<'a, 'b> FromUriParam<Path, &'a &'b str> for PathBuf
A no cost conversion allowing an &&str
to be used in place of a PathBuf
.
sourcefn from_uri_param(param: &'a &'b str) -> &'b Path
fn from_uri_param(param: &'a &'b str) -> &'b Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'a> FromUriParam<Path, &'a Path> for &'a Path
impl<'a> FromUriParam<Path, &'a Path> for &'a Path
sourcefn from_uri_param(param: &'a Path) -> &'a Path
fn from_uri_param(param: &'a Path) -> &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'a> FromUriParam<Path, &'a Path> for PathBuf
impl<'a> FromUriParam<Path, &'a Path> for PathBuf
sourcefn from_uri_param(param: &'a Path) -> &'a Path
fn from_uri_param(param: &'a Path) -> &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'a> FromUriParam<Path, &'a str> for PathBuf
impl<'a> FromUriParam<Path, &'a str> for PathBuf
A no cost conversion allowing an &str
to be used in place of a PathBuf
.
sourcefn from_uri_param(param: &'a str) -> &'a Path
fn from_uri_param(param: &'a str) -> &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x &'a Path> for &'a Path
impl<'x, 'a> FromUriParam<Path, &'x &'a Path> for &'a Path
sourcefn from_uri_param(param: &'x &'a Path) -> &'x &'a Path
fn from_uri_param(param: &'x &'a Path) -> &'x &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x &'a Path> for PathBuf
impl<'x, 'a> FromUriParam<Path, &'x &'a Path> for PathBuf
sourcefn from_uri_param(param: &'x &'a Path) -> &'x &'a Path
fn from_uri_param(param: &'x &'a Path) -> &'x &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x> FromUriParam<Path, &'x PathBuf> for PathBuf
impl<'x> FromUriParam<Path, &'x PathBuf> for PathBuf
sourcefn from_uri_param(param: &'x PathBuf) -> &'x PathBuf
fn from_uri_param(param: &'x PathBuf) -> &'x PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x PathBuf> for &'a Path
impl<'x, 'a> FromUriParam<Path, &'x PathBuf> for &'a Path
sourcefn from_uri_param(param: &'x PathBuf) -> &'x PathBuf
fn from_uri_param(param: &'x PathBuf) -> &'x PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x mut &'a Path> for &'a Path
impl<'x, 'a> FromUriParam<Path, &'x mut &'a Path> for &'a Path
sourcefn from_uri_param(param: &'x mut &'a Path) -> &'x mut &'a Path
fn from_uri_param(param: &'x mut &'a Path) -> &'x mut &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x mut &'a Path> for PathBuf
impl<'x, 'a> FromUriParam<Path, &'x mut &'a Path> for PathBuf
sourcefn from_uri_param(param: &'x mut &'a Path) -> &'x mut &'a Path
fn from_uri_param(param: &'x mut &'a Path) -> &'x mut &'a Path
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x> FromUriParam<Path, &'x mut PathBuf> for PathBuf
impl<'x> FromUriParam<Path, &'x mut PathBuf> for PathBuf
sourcefn from_uri_param(param: &'x mut PathBuf) -> &'x mut PathBuf
fn from_uri_param(param: &'x mut PathBuf) -> &'x mut PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'x, 'a> FromUriParam<Path, &'x mut PathBuf> for &'a Path
impl<'x, 'a> FromUriParam<Path, &'x mut PathBuf> for &'a Path
sourcefn from_uri_param(param: &'x mut PathBuf) -> &'x mut PathBuf
fn from_uri_param(param: &'x mut PathBuf) -> &'x mut PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl FromUriParam<Path, PathBuf> for PathBuf
impl FromUriParam<Path, PathBuf> for PathBuf
sourcefn from_uri_param(param: PathBuf) -> PathBuf
fn from_uri_param(param: PathBuf) -> PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl<'a> FromUriParam<Path, PathBuf> for &'a Path
impl<'a> FromUriParam<Path, PathBuf> for &'a Path
sourcefn from_uri_param(param: PathBuf) -> PathBuf
fn from_uri_param(param: PathBuf) -> PathBuf
Converts a value of type T
into a value of type Self::Target
. The
resulting value of type Self::Target
will be rendered into a URI using
its UriDisplay
implementation. Read more
sourceimpl UriDisplay<Path> for Path
impl UriDisplay<Path> for Path
Percent-encodes each segment in the path and normalizes separators.
sourceimpl UriDisplay<Path> for PathBuf
impl UriDisplay<Path> for PathBuf
Percent-encodes each segment in the path and normalizes separators.
impl Copy for Path
Auto Trait Implementations
impl RefUnwindSafe for Path
impl Send for Path
impl Sync for Path
impl Unpin for Path
impl UnwindSafe for Path
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> IntoCollection<T> for T
impl<T> IntoCollection<T> for T
sourceimpl<T> ToOwned for T where
T: Clone,
impl<T> ToOwned for T where
T: Clone,
type Owned = T
type Owned = T
The resulting type after obtaining ownership.
sourcefn clone_into(&self, target: &mut T)
fn clone_into(&self, target: &mut T)
toowned_clone_into
)Uses borrowed data to replace owned data, usually by cloning. Read more