URIStr

Struct URIStr 

Source
pub struct URIStr { /* private fields */ }

Implementations§

Source§

impl URIStr

Source

pub fn resolve(&self, reference: &Self) -> URIString

Resolve the relative reference reference using self as the base URI.

self must be convertible to an absolute URI through fragment removal and normalization.

§Reference
Source

pub fn as_escaped_str(&self) -> &str

Return the escaped URI string.

Source

pub fn as_unescaped_str(&self) -> Option<Cow<'_, str>>

Return the unescaped URI string.
If unescaping fails, return None.

Source

pub fn is_absolute(&self) -> bool

Source

pub fn is_relative(&self) -> bool

Source

pub fn scheme(&self) -> Option<&str>

§Reference

3.1. Scheme

Source

pub fn authority(&self) -> Option<&str>

§Reference

3.2. Authority

Source

pub fn userinfo(&self) -> Option<&str>

Source

pub fn host(&self) -> Option<&str>

§Reference

3.2.2. Host

Source

pub fn port(&self) -> Option<&str>

§Reference

3.2.3. Port

Source

pub fn path(&self) -> &str

§Reference

3.3. Path

Source

pub fn query(&self) -> Option<&str>

§Reference

3.4. Query

Source

pub fn fragment(&self) -> Option<&str>

§Reference

3.5. Fragment

Source

pub fn components(&self) -> Components<'_>

Return an iterator that scans the URI components.

Trait Implementations§

Source§

impl AsRef<URIStr> for URIStr

Source§

fn as_ref(&self) -> &URIStr

Converts this type into a shared reference of the (usually inferred) input type.
Source§

impl AsRef<URIStr> for URIString

Source§

fn as_ref(&self) -> &URIStr

Converts this type into a shared reference of the (usually inferred) input type.
Source§

impl Borrow<URIStr> for URIString

Source§

fn borrow(&self) -> &URIStr

Immutably borrows from an owned value. Read more
Source§

impl Clone for Box<URIStr>

Source§

fn clone(&self) -> Self

Returns a duplicate of the value. Read more
1.0.0§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for URIStr

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl From<&URIStr> for Arc<URIStr>

Source§

fn from(value: &URIStr) -> Self

Converts to this type from the input type.
Source§

impl From<&URIStr> for Box<URIStr>

Source§

fn from(value: &URIStr) -> Self

Converts to this type from the input type.
Source§

impl From<&URIStr> for Rc<URIStr>

Source§

fn from(value: &URIStr) -> Self

Converts to this type from the input type.
Source§

impl From<&URIStr> for URIString

Source§

fn from(value: &URIStr) -> Self

Converts to this type from the input type.
Source§

impl From<URIString> for Box<URIStr>

Source§

fn from(value: URIString) -> Box<URIStr>

Converts to this type from the input type.
Source§

impl Hash for URIStr

Source§

fn hash<__H: Hasher>(&self, state: &mut __H)

Feeds this value into the given Hasher. Read more
Source§

impl PartialEq for URIStr

Source§

fn eq(&self, other: &URIStr) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl ToOwned for URIStr

Source§

type Owned = URIString

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> Self::Owned

Creates owned data from borrowed data, usually by cloning. Read more
1.63.0§

fn clone_into(&self, target: &mut Self::Owned)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl Eq for URIStr

Source§

impl StructuralPartialEq for URIStr

Auto Trait Implementations§

§

impl Freeze for URIStr

§

impl RefUnwindSafe for URIStr

§

impl Send for URIStr

§

impl !Sized for URIStr

§

impl Sync for URIStr

§

impl Unpin for URIStr

§

impl UnwindSafe for URIStr

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more