[][src]Struct url_serde::Ser

pub struct Ser<'a, T: 'a>(_);

A wrapper to serialize rust-url types.

This is useful with functions such as serde_json::to_string.

Values of this type can only be passed to the serde::Serialize trait.

Methods

impl<'a, T> Ser<'a, T> where
    Ser<'a, T>: Serialize
[src]

pub fn new(value: &'a T) -> Self[src]

Returns a new Ser wrapper.

Trait Implementations

impl<'a, T: Debug + 'a> Debug for Ser<'a, T>[src]

impl<'a> Serialize for Ser<'a, Url>[src]

Serializes this URL into a serde stream.

impl<'a> Serialize for Ser<'a, Option<Url>>[src]

Serializes this Option into a serde stream.

impl<'a, String> Serialize for Ser<'a, Host<String>> where
    String: AsRef<str>, 
[src]

Auto Trait Implementations

impl<'a, T> Unpin for Ser<'a, T>

impl<'a, T> Sync for Ser<'a, T> where
    T: Sync

impl<'a, T> Send for Ser<'a, T> where
    T: Sync

impl<'a, T> UnwindSafe for Ser<'a, T> where
    T: RefUnwindSafe

impl<'a, T> RefUnwindSafe for Ser<'a, T> where
    T: RefUnwindSafe

Blanket Implementations

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]