Struct launchdarkly_server_sdk::UserBuilder
source · [−]pub struct UserBuilder { /* private fields */ }
Expand description
Contains methods for configuring a user.
Implementations
sourceimpl UserBuilder
impl UserBuilder
sourcepub fn new(key: impl Into<String>) -> UserBuilder
pub fn new(key: impl Into<String>) -> UserBuilder
Create a new user builder, setting the user key value to key
.
sourcepub fn secondary(&mut self, secondary: impl Into<String>) -> &mut UserBuilder
pub fn secondary(&mut self, secondary: impl Into<String>) -> &mut UserBuilder
Set the secondary attribute for this builder instance.
sourcepub fn ip(&mut self, ip: impl Into<String>) -> &mut UserBuilder
pub fn ip(&mut self, ip: impl Into<String>) -> &mut UserBuilder
Set the ip attribute for this builder instance.
sourcepub fn country(&mut self, country: impl Into<String>) -> &mut UserBuilder
pub fn country(&mut self, country: impl Into<String>) -> &mut UserBuilder
Set the country attribute for this builder instance.
sourcepub fn email(&mut self, email: impl Into<String>) -> &mut UserBuilder
pub fn email(&mut self, email: impl Into<String>) -> &mut UserBuilder
Set the email attribute for this builder instance.
sourcepub fn first_name(&mut self, first_name: impl Into<String>) -> &mut UserBuilder
pub fn first_name(&mut self, first_name: impl Into<String>) -> &mut UserBuilder
Set the first name attribute for this builder instance.
sourcepub fn last_name(&mut self, last_name: impl Into<String>) -> &mut UserBuilder
pub fn last_name(&mut self, last_name: impl Into<String>) -> &mut UserBuilder
Set the last name attribute for this builder instance.
sourcepub fn avatar(&mut self, avatar: impl Into<String>) -> &mut UserBuilder
pub fn avatar(&mut self, avatar: impl Into<String>) -> &mut UserBuilder
Set the avatar attribute for this builder instance.
sourcepub fn name(&mut self, name: impl Into<String>) -> &mut UserBuilder
pub fn name(&mut self, name: impl Into<String>) -> &mut UserBuilder
Set the name attribute for this builder instance.
sourcepub fn anonymous(&mut self, anonymous: bool) -> &mut UserBuilder
pub fn anonymous(&mut self, anonymous: bool) -> &mut UserBuilder
Set the anonymous attribute for this builder instance.
sourcepub fn custom(
&mut self,
custom: HashMap<String, AttributeValue, RandomState>
) -> &mut UserBuilder
pub fn custom(
&mut self,
custom: HashMap<String, AttributeValue, RandomState>
) -> &mut UserBuilder
Set the custom attributes for this builder instance.
sourcepub fn private_attributes(
&mut self,
private_attributes: HashSet<String, RandomState>
) -> &mut UserBuilder
pub fn private_attributes(
&mut self,
private_attributes: HashSet<String, RandomState>
) -> &mut UserBuilder
Set a list of attributes that are considered private for this user only.
Auto Trait Implementations
impl RefUnwindSafe for UserBuilder
impl Send for UserBuilder
impl Sync for UserBuilder
impl Unpin for UserBuilder
impl UnwindSafe for UserBuilder
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<T> Instrument for T
impl<T> Instrument for T
sourcefn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
sourcefn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
sourceimpl<T> WithSubscriber for T
impl<T> WithSubscriber for T
sourcefn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
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
sourcefn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more