[][src]Enum ruma_client_api::r0::session::login::UserInfo

pub enum UserInfo<'a> {
    MatrixId(&'a str),
    ThirdPartyId {
        address: &'a str,
        medium: Medium,
    },
    PhoneNumber {
        country: &'a str,
        phone: &'a str,
    },
}

Identification information for the user.

Variants

MatrixId(&'a str)

Either a fully qualified Matrix user ID, or just the localpart (as part of the 'identifier' field).

ThirdPartyId

Third party identifier (as part of the 'identifier' field).

Fields of ThirdPartyId

address: &'a str

Third party identifier for the user.

medium: Medium

The medium of the identifier.

PhoneNumber

Same as third-party identification with medium == msisdn, but with a non-canonicalised phone number.

Fields of PhoneNumber

country: &'a str

The country that the phone number is from.

phone: &'a str

The phone number.

Trait Implementations

impl<'a> Clone for UserInfo<'a>[src]

impl<'a> Debug for UserInfo<'a>[src]

impl<'a> Eq for UserInfo<'a>[src]

impl<'a> Outgoing for UserInfo<'a>[src]

type Incoming = IncomingUserInfo

The 'Incoming' variant of Self.

impl<'a> PartialEq<UserInfo<'a>> for UserInfo<'a>[src]

impl<'a> Serialize for UserInfo<'a>[src]

impl<'a> StructuralEq for UserInfo<'a>[src]

impl<'a> StructuralPartialEq for UserInfo<'a>[src]

Auto Trait Implementations

impl<'a> RefUnwindSafe for UserInfo<'a>[src]

impl<'a> Send for UserInfo<'a>[src]

impl<'a> Sync for UserInfo<'a>[src]

impl<'a> Unpin for UserInfo<'a>[src]

impl<'a> UnwindSafe for UserInfo<'a>[src]

Blanket Implementations

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

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

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

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

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

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

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.