Struct statsig::StatsigUser
source · pub struct StatsigUser {
pub user_id: Option<String>,
pub email: Option<String>,
pub ip: Option<String>,
pub user_agent: Option<String>,
pub country: Option<String>,
pub locale: Option<String>,
pub app_version: Option<String>,
pub custom: Option<HashMap<String, Value>>,
pub private_attributes: Option<HashMap<String, Value>>,
pub custom_ids: Option<HashMap<String, String>>,
/* private fields */
}
Fields§
§user_id: Option<String>
§email: Option<String>
§ip: Option<String>
§user_agent: Option<String>
§country: Option<String>
§locale: Option<String>
§app_version: Option<String>
§custom: Option<HashMap<String, Value>>
§private_attributes: Option<HashMap<String, Value>>
§custom_ids: Option<HashMap<String, String>>
Implementations§
source§impl StatsigUser
impl StatsigUser
pub fn get_unit_id(&self, id_type: &String) -> Option<String>
pub fn get_user_value(&self, field: &Option<String>) -> Value
pub fn get_value_from_environment(&self, field: &Option<String>) -> Value
source§impl StatsigUser
impl StatsigUser
pub fn with_user_id(user_id: String) -> Self
pub fn with_custom_ids(custom_ids: HashMap<String, String>) -> Self
Trait Implementations§
source§impl Clone for StatsigUser
impl Clone for StatsigUser
source§fn clone(&self) -> StatsigUser
fn clone(&self) -> StatsigUser
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl<'de> Deserialize<'de> for StatsigUser
impl<'de> Deserialize<'de> for StatsigUser
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for StatsigUser
impl RefUnwindSafe for StatsigUser
impl Send for StatsigUser
impl Sync for StatsigUser
impl Unpin for StatsigUser
impl UnwindSafe for StatsigUser
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more