Struct got_ya_id::apps::user::models::NewUser[][src]

pub struct NewUser<'b> {
    pub username: Cow<'b, str>,
    pub password: Cow<'b, str>,
    pub access_level: Option<i32>,
}

Temporary holds new User data User Record for new User entries

Fields

username: Cow<'b, str>password: Cow<'b, str>access_level: Option<i32>

Implementations

impl<'a> NewUser<'a>[src]

pub fn save(&mut self, new_email: &str) -> Result<User, Box<dyn stdError>>[src]

Saves a new user record to the db

Returns

User

Trait Implementations

impl<'de, 'b> Deserialize<'de> for NewUser<'b>[src]

impl<'b, 'insert> Insertable<table> for NewUser<'b>[src]

type Values = <(Option<Eq<username, Cow<'b, str>>>, Option<Eq<password, Cow<'b, str>>>, Option<Eq<access_level, i32>>) as Insertable<table>>::Values

The VALUES clause to insert these records Read more

impl<'b, 'insert> Insertable<table> for &'insert NewUser<'b>[src]

type Values = <(Option<Eq<username, &'insert Cow<'b, str>>>, Option<Eq<password, &'insert Cow<'b, str>>>, Option<Eq<access_level, &'insert i32>>) as Insertable<table>>::Values

The VALUES clause to insert these records Read more

impl<'b> Serialize for NewUser<'b>[src]

impl<'b, 'insert> UndecoratedInsertRecord<table> for NewUser<'b>[src]

Auto Trait Implementations

impl<'b> RefUnwindSafe for NewUser<'b>

impl<'b> Send for NewUser<'b>

impl<'b> Sync for NewUser<'b>

impl<'b> Unpin for NewUser<'b>

impl<'b> UnwindSafe for NewUser<'b>

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

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

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

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

impl<T, U> IntoPy<U> for T where
    U: FromPy<T>, 
[src]

impl<T> IntoSql for T[src]

impl<T> Same<T> for T

type Output = T

Should always be Self

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>,