Struct uriparse::uri::URI [−][src]
pub struct URI<'uri> { /* fields omitted */ }
Methods
impl<'uri> URI<'uri>
[src]
impl<'uri> URI<'uri>
pub fn from_parts<'new_uri, SchemeType, AuthorityType, PathType, QueryType, FragmentType, SchemeError, AuthorityError, PathError, QueryError, FragmentError>(
scheme: SchemeType,
authority: Option<AuthorityType>,
path: PathType,
query: Option<QueryType>,
fragment: Option<FragmentType>
) -> Result<URI<'new_uri>, InvalidURI> where
Scheme<'new_uri>: TryFrom<SchemeType, Error = SchemeError>,
Authority<'new_uri>: TryFrom<AuthorityType, Error = AuthorityError>,
Path<'new_uri>: TryFrom<PathType, Error = PathError>,
Query<'new_uri>: TryFrom<QueryType, Error = QueryError>,
Fragment<'new_uri>: TryFrom<FragmentType, Error = FragmentError>,
InvalidURIReference: From<SchemeError> + From<AuthorityError> + From<PathError> + From<QueryError> + From<FragmentError>,
[src]
pub fn from_parts<'new_uri, SchemeType, AuthorityType, PathType, QueryType, FragmentType, SchemeError, AuthorityError, PathError, QueryError, FragmentError>(
scheme: SchemeType,
authority: Option<AuthorityType>,
path: PathType,
query: Option<QueryType>,
fragment: Option<FragmentType>
) -> Result<URI<'new_uri>, InvalidURI> where
Scheme<'new_uri>: TryFrom<SchemeType, Error = SchemeError>,
Authority<'new_uri>: TryFrom<AuthorityType, Error = AuthorityError>,
Path<'new_uri>: TryFrom<PathType, Error = PathError>,
Query<'new_uri>: TryFrom<QueryType, Error = QueryError>,
Fragment<'new_uri>: TryFrom<FragmentType, Error = FragmentError>,
InvalidURIReference: From<SchemeError> + From<AuthorityError> + From<PathError> + From<QueryError> + From<FragmentError>,
pub fn fragment(&self) -> Option<&Fragment<'uri>>
[src]
pub fn fragment(&self) -> Option<&Fragment<'uri>>
pub fn has_fragment(&self) -> bool
[src]
pub fn has_fragment(&self) -> bool
pub fn has_password(&self) -> bool
[src]
pub fn has_password(&self) -> bool
pub fn has_query(&self) -> bool
[src]
pub fn has_query(&self) -> bool
pub fn has_username(&self) -> bool
[src]
pub fn has_username(&self) -> bool
pub fn host(&self) -> Option<&Host<'uri>>
[src]
pub fn host(&self) -> Option<&Host<'uri>>
pub fn into_parts(
self
) -> (Scheme<'uri>, Option<Authority<'uri>>, Path<'uri>, Option<Query<'uri>>, Option<Fragment<'uri>>)
[src]
pub fn into_parts(
self
) -> (Scheme<'uri>, Option<Authority<'uri>>, Path<'uri>, Option<Query<'uri>>, Option<Fragment<'uri>>)
pub fn path(&self) -> &Path<'uri>
[src]
pub fn path(&self) -> &Path<'uri>
pub fn password(&self) -> Option<&Password<'uri>>
[src]
pub fn password(&self) -> Option<&Password<'uri>>
pub fn port(&self) -> Option<u16>
[src]
pub fn port(&self) -> Option<u16>
pub fn query(&self) -> Option<&Query<'uri>>
[src]
pub fn query(&self) -> Option<&Query<'uri>>
pub fn scheme(&self) -> &Scheme<'uri>
[src]
pub fn scheme(&self) -> &Scheme<'uri>
pub fn username(&self) -> Option<&Username>
[src]
pub fn username(&self) -> Option<&Username>
Trait Implementations
impl<'uri> Clone for URI<'uri>
[src]
impl<'uri> Clone for URI<'uri>
fn clone(&self) -> URI<'uri>
[src]
fn clone(&self) -> URI<'uri>
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
impl<'uri> Debug for URI<'uri>
[src]
impl<'uri> Debug for URI<'uri>
fn fmt(&self, f: &mut Formatter) -> Result
[src]
fn fmt(&self, f: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<'uri> Eq for URI<'uri>
[src]
impl<'uri> Eq for URI<'uri>
impl<'uri> Hash for URI<'uri>
[src]
impl<'uri> Hash for URI<'uri>
fn hash<__H: Hasher>(&self, state: &mut __H)
[src]
fn hash<__H: Hasher>(&self, state: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0[src]
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl<'uri> PartialEq for URI<'uri>
[src]
impl<'uri> PartialEq for URI<'uri>
fn eq(&self, other: &URI<'uri>) -> bool
[src]
fn eq(&self, other: &URI<'uri>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &URI<'uri>) -> bool
[src]
fn ne(&self, other: &URI<'uri>) -> bool
This method tests for !=
.
impl<'uri> Display for URI<'uri>
[src]
impl<'uri> Display for URI<'uri>
fn fmt(&self, formatter: &mut Formatter) -> Result
[src]
fn fmt(&self, formatter: &mut Formatter) -> Result
Formats the value using the given formatter. Read more
impl<'uri> PartialEq<str> for URI<'uri>
[src]
impl<'uri> PartialEq<str> for URI<'uri>
fn eq(&self, other: &str) -> bool
[src]
fn eq(&self, other: &str) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl<'uri> PartialEq<URI<'uri>> for str
[src]
impl<'uri> PartialEq<URI<'uri>> for str
fn eq(&self, other: &URI<'uri>) -> bool
[src]
fn eq(&self, other: &URI<'uri>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl<'a, 'uri> PartialEq<&'a str> for URI<'uri>
[src]
impl<'a, 'uri> PartialEq<&'a str> for URI<'uri>
fn eq(&self, other: &&'a str) -> bool
[src]
fn eq(&self, other: &&'a str) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl<'a, 'uri> PartialEq<URI<'uri>> for &'a str
[src]
impl<'a, 'uri> PartialEq<URI<'uri>> for &'a str
fn eq(&self, other: &URI<'uri>) -> bool
[src]
fn eq(&self, other: &URI<'uri>) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, other: &Rhs) -> bool
1.0.0[src]
fn ne(&self, other: &Rhs) -> bool
This method tests for !=
.
impl<'uri> TryFrom<&'uri [u8]> for URI<'uri>
[src]
impl<'uri> TryFrom<&'uri [u8]> for URI<'uri>
type Error = InvalidURI
try_from
)The type returned in the event of a conversion error.
fn try_from(value: &'uri [u8]) -> Result<Self, Self::Error>
[src]
fn try_from(value: &'uri [u8]) -> Result<Self, Self::Error>
try_from
)Performs the conversion.
impl<'uri> TryFrom<&'uri str> for URI<'uri>
[src]
impl<'uri> TryFrom<&'uri str> for URI<'uri>