[][src]Struct covidcotra::Identity

pub struct Identity { /* fields omitted */ }

Represents the unique identity of a person with auth info.

The identity is to kept private on the device and not shared with anyone other than authorities when you are infected. After it has every been shared it must by cycled.

For sharing for subscription or cehck-in purposes the hashed identity must be used instead.

Methods

impl Identity[src]

pub fn unique() -> Identity[src]

Creates a new random identity.

pub fn unique_id(&self) -> &UniqueIdentity[src]

Returns the internal unique identity.

pub fn hashed_id(&self) -> &HashedIdentity[src]

Returns the hashed identity.

pub fn new_share_id(&self, public_key: &PublicKey) -> ShareIdentity[src]

Creates a new shareable identity.

Trait Implementations

impl Clone for Identity[src]

impl Debug for Identity[src]

impl<'de> Deserialize<'de> for Identity[src]

impl Serialize for Identity[src]

Auto Trait Implementations

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> DeserializeOwned for T where
    T: Deserialize<'de>, 
[src]

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

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

impl<T> Same<T> for T

type Output = T

Should always be Self

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.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>,