gitlab::api::users

Struct CreateUserBuilder

source
pub struct CreateUserBuilder<'a> { /* private fields */ }
Expand description

Builder for CreateUser.

Implementations§

source§

impl<'a> CreateUserBuilder<'a>

source

pub fn email<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The email of the user.

source

pub fn name<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The name of the user.

source

pub fn username<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The username of the user.

source

pub fn password<VALUE: Into<NewUserPassword<'a>>>( &mut self, value: VALUE, ) -> &mut Self

The password of the user.

source

pub fn skip_confirmation(&mut self, value: bool) -> &mut Self

Skip confirmation for newly created user

source

pub fn admin(&mut self, value: bool) -> &mut Self

Whether the user is an administrator or not.

source

pub fn auditor(&mut self, value: bool) -> &mut Self

Whether the user is an auditor or not.

source

pub fn external(&mut self, value: bool) -> &mut Self

Whether the user is provided by an external entity or not.

source

pub fn group_id_for_saml(&mut self, value: u64) -> &mut Self

The ID of the group for SAML.

source

pub fn note<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

Administrator notes for the user.

source

pub fn external_provider(&mut self, value: ExternalProvider<'a>) -> &mut Self

Set the external provider identity for the user.

source

pub fn color_scheme_id(&mut self, value: u64) -> &mut Self

The ID of the color scheme to use for the user.

source

pub fn private_profile(&mut self, value: bool) -> &mut Self

Whether the user’s profile is set to private or not.

source

pub fn theme_id(&mut self, value: u64) -> &mut Self

The ID of the theme to use for the user.

source

pub fn view_diffs_file_by_file(&mut self, value: bool) -> &mut Self

Whether the user prefers viewing diffs file-by-file or not.

source

pub fn can_create_group(&mut self, value: bool) -> &mut Self

Whether the user can create groups or not.

source

pub fn extra_shared_runners_minutes_limit(&mut self, value: u64) -> &mut Self

Extra minutes on shared runners for the user.

source

pub fn projects_limit(&mut self, value: u64) -> &mut Self

The number of projects the user may create.

source

pub fn shared_runners_minutes_limit(&mut self, value: u64) -> &mut Self

The limit shared runners usage (in minutes) for the user.

source

pub fn bio<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

Biographical information about the user.

source

pub fn commit_email<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self

The user’s commit email address.

source

pub fn linkedin<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s LinkedIn URL.

source

pub fn location<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s location.

source

pub fn organization<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self

The user’s organization.

source

pub fn pronouns<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s pronouns.

source

pub fn public_email<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self

The user’s public email address.

source

pub fn skype<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s Skype ID.

source

pub fn twitter<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s Twitter ID.

source

pub fn discord<VALUE: Into<Cow<'a, str>>>(&mut self, value: VALUE) -> &mut Self

The user’s Discord ID.

source

pub fn website_url<VALUE: Into<Cow<'a, str>>>( &mut self, value: VALUE, ) -> &mut Self

The user’s website URL.

source

pub fn build(&self) -> Result<CreateUser<'a>, CreateUserBuilderError>

Builds a new CreateUser.

§Errors

If a required field has not been initialized.

Trait Implementations§

source§

impl<'a> Clone for CreateUserBuilder<'a>

source§

fn clone(&self) -> CreateUserBuilder<'a>

Returns a copy of the value. Read more
1.0.0 · source§

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

Performs copy-assignment from source. Read more
source§

impl<'a> Default for CreateUserBuilder<'a>

source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<'a> Freeze for CreateUserBuilder<'a>

§

impl<'a> RefUnwindSafe for CreateUserBuilder<'a>

§

impl<'a> Send for CreateUserBuilder<'a>

§

impl<'a> Sync for CreateUserBuilder<'a>

§

impl<'a> Unpin for CreateUserBuilder<'a>

§

impl<'a> UnwindSafe for CreateUserBuilder<'a>

Blanket Implementations§

source§

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

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

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

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

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

source§

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

Mutably borrows from an owned value. Read more
source§

impl<T> CloneToUninit for T
where T: Clone,

source§

unsafe fn clone_to_uninit(&self, dst: *mut T)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dst. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T> Instrument for T

source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

source§

impl<T> IntoEither for T

source§

fn into_either(self, into_left: bool) -> Either<Self, Self>

Converts self into a Left variant of Either<Self, Self> if into_left is true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

Converts self into a Left variant of Either<Self, Self> if into_left(&self) returns true. Converts self into a Right variant of Either<Self, Self> otherwise. Read more
source§

impl<T> ToOwned for T
where T: Clone,

source§

type Owned = T

The resulting type after obtaining ownership.
source§

fn to_owned(&self) -> T

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

fn clone_into(&self, target: &mut T)

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

impl<T, U> TryFrom<U> for T
where U: Into<T>,

source§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

source§

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

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
source§

impl<T> WithSubscriber for T

source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more