pub struct SlackUser {Show 14 fields
pub id: SlackUserId,
pub team_id: Option<SlackTeamId>,
pub name: Option<String>,
pub locale: Option<SlackLocale>,
pub profile: Option<SlackUserProfile>,
pub flags: SlackUserFlags,
pub tz: Option<String>,
pub tz_label: Option<String>,
pub tz_offset: Option<i32>,
pub updated: Option<SlackDateTime>,
pub deleted: Option<bool>,
pub color: Option<SlackColor>,
pub real_name: Option<String>,
pub enterprise_user: Option<SlackEnterpriseUser>,
}Fields§
§id: SlackUserId§team_id: Option<SlackTeamId>§name: Option<String>§locale: Option<SlackLocale>§profile: Option<SlackUserProfile>§flags: SlackUserFlags§tz: Option<String>§tz_label: Option<String>§tz_offset: Option<i32>§updated: Option<SlackDateTime>§deleted: Option<bool>§color: Option<SlackColor>§real_name: Option<String>§enterprise_user: Option<SlackEnterpriseUser>Implementations§
Source§impl SlackUser
impl SlackUser
Sourcepub fn new(id: SlackUserId, flags: SlackUserFlags) -> Self
pub fn new(id: SlackUserId, flags: SlackUserFlags) -> Self
Creates a new SlackUser from its required fields. Option fields start as None, and fields with #[default] take their default.
Sourcepub fn id(&mut self, value: SlackUserId) -> &mut Self
pub fn id(&mut self, value: SlackUserId) -> &mut Self
Sets id to value.
Sourcepub fn with_id(self, value: SlackUserId) -> Self
pub fn with_id(self, value: SlackUserId) -> Self
Returns self with id set to value.
Sourcepub fn team_id(&mut self, value: SlackTeamId) -> &mut Self
pub fn team_id(&mut self, value: SlackTeamId) -> &mut Self
Sets team_id to Some(value).
Sourcepub fn reset_team_id(&mut self) -> &mut Self
pub fn reset_team_id(&mut self) -> &mut Self
Sets team_id to None.
Sourcepub fn mopt_team_id(&mut self, value: Option<SlackTeamId>) -> &mut Self
pub fn mopt_team_id(&mut self, value: Option<SlackTeamId>) -> &mut Self
Sets team_id to the given Option.
Sourcepub fn with_team_id(self, value: SlackTeamId) -> Self
pub fn with_team_id(self, value: SlackTeamId) -> Self
Returns self with team_id set to Some(value).
Sourcepub fn without_team_id(self) -> Self
pub fn without_team_id(self) -> Self
Returns self with team_id set to None.
Sourcepub fn opt_team_id(self, value: Option<SlackTeamId>) -> Self
pub fn opt_team_id(self, value: Option<SlackTeamId>) -> Self
Returns self with team_id set to the given Option.
Sourcepub fn reset_name(&mut self) -> &mut Self
pub fn reset_name(&mut self) -> &mut Self
Sets name to None.
Sourcepub fn without_name(self) -> Self
pub fn without_name(self) -> Self
Returns self with name set to None.
Sourcepub fn opt_name(self, value: Option<String>) -> Self
pub fn opt_name(self, value: Option<String>) -> Self
Returns self with name set to the given Option.
Sourcepub fn locale(&mut self, value: SlackLocale) -> &mut Self
pub fn locale(&mut self, value: SlackLocale) -> &mut Self
Sets locale to Some(value).
Sourcepub fn reset_locale(&mut self) -> &mut Self
pub fn reset_locale(&mut self) -> &mut Self
Sets locale to None.
Sourcepub fn mopt_locale(&mut self, value: Option<SlackLocale>) -> &mut Self
pub fn mopt_locale(&mut self, value: Option<SlackLocale>) -> &mut Self
Sets locale to the given Option.
Sourcepub fn with_locale(self, value: SlackLocale) -> Self
pub fn with_locale(self, value: SlackLocale) -> Self
Returns self with locale set to Some(value).
Sourcepub fn without_locale(self) -> Self
pub fn without_locale(self) -> Self
Returns self with locale set to None.
Sourcepub fn opt_locale(self, value: Option<SlackLocale>) -> Self
pub fn opt_locale(self, value: Option<SlackLocale>) -> Self
Returns self with locale set to the given Option.
Sourcepub fn profile(&mut self, value: SlackUserProfile) -> &mut Self
pub fn profile(&mut self, value: SlackUserProfile) -> &mut Self
Sets profile to Some(value).
Sourcepub fn reset_profile(&mut self) -> &mut Self
pub fn reset_profile(&mut self) -> &mut Self
Sets profile to None.
Sourcepub fn mopt_profile(&mut self, value: Option<SlackUserProfile>) -> &mut Self
pub fn mopt_profile(&mut self, value: Option<SlackUserProfile>) -> &mut Self
Sets profile to the given Option.
Sourcepub fn with_profile(self, value: SlackUserProfile) -> Self
pub fn with_profile(self, value: SlackUserProfile) -> Self
Returns self with profile set to Some(value).
Sourcepub fn without_profile(self) -> Self
pub fn without_profile(self) -> Self
Returns self with profile set to None.
Sourcepub fn opt_profile(self, value: Option<SlackUserProfile>) -> Self
pub fn opt_profile(self, value: Option<SlackUserProfile>) -> Self
Returns self with profile set to the given Option.
Sourcepub fn flags(&mut self, value: SlackUserFlags) -> &mut Self
pub fn flags(&mut self, value: SlackUserFlags) -> &mut Self
Sets flags to value.
Sourcepub fn with_flags(self, value: SlackUserFlags) -> Self
pub fn with_flags(self, value: SlackUserFlags) -> Self
Returns self with flags set to value.
Sourcepub fn without_tz(self) -> Self
pub fn without_tz(self) -> Self
Returns self with tz set to None.
Sourcepub fn opt_tz(self, value: Option<String>) -> Self
pub fn opt_tz(self, value: Option<String>) -> Self
Returns self with tz set to the given Option.
Sourcepub fn reset_tz_label(&mut self) -> &mut Self
pub fn reset_tz_label(&mut self) -> &mut Self
Sets tz_label to None.
Sourcepub fn mopt_tz_label(&mut self, value: Option<String>) -> &mut Self
pub fn mopt_tz_label(&mut self, value: Option<String>) -> &mut Self
Sets tz_label to the given Option.
Sourcepub fn with_tz_label(self, value: String) -> Self
pub fn with_tz_label(self, value: String) -> Self
Returns self with tz_label set to Some(value).
Sourcepub fn without_tz_label(self) -> Self
pub fn without_tz_label(self) -> Self
Returns self with tz_label set to None.
Sourcepub fn opt_tz_label(self, value: Option<String>) -> Self
pub fn opt_tz_label(self, value: Option<String>) -> Self
Returns self with tz_label set to the given Option.
Sourcepub fn reset_tz_offset(&mut self) -> &mut Self
pub fn reset_tz_offset(&mut self) -> &mut Self
Sets tz_offset to None.
Sourcepub fn mopt_tz_offset(&mut self, value: Option<i32>) -> &mut Self
pub fn mopt_tz_offset(&mut self, value: Option<i32>) -> &mut Self
Sets tz_offset to the given Option.
Sourcepub fn with_tz_offset(self, value: i32) -> Self
pub fn with_tz_offset(self, value: i32) -> Self
Returns self with tz_offset set to Some(value).
Sourcepub fn without_tz_offset(self) -> Self
pub fn without_tz_offset(self) -> Self
Returns self with tz_offset set to None.
Sourcepub fn opt_tz_offset(self, value: Option<i32>) -> Self
pub fn opt_tz_offset(self, value: Option<i32>) -> Self
Returns self with tz_offset set to the given Option.
Sourcepub fn updated(&mut self, value: SlackDateTime) -> &mut Self
pub fn updated(&mut self, value: SlackDateTime) -> &mut Self
Sets updated to Some(value).
Sourcepub fn reset_updated(&mut self) -> &mut Self
pub fn reset_updated(&mut self) -> &mut Self
Sets updated to None.
Sourcepub fn mopt_updated(&mut self, value: Option<SlackDateTime>) -> &mut Self
pub fn mopt_updated(&mut self, value: Option<SlackDateTime>) -> &mut Self
Sets updated to the given Option.
Sourcepub fn with_updated(self, value: SlackDateTime) -> Self
pub fn with_updated(self, value: SlackDateTime) -> Self
Returns self with updated set to Some(value).
Sourcepub fn without_updated(self) -> Self
pub fn without_updated(self) -> Self
Returns self with updated set to None.
Sourcepub fn opt_updated(self, value: Option<SlackDateTime>) -> Self
pub fn opt_updated(self, value: Option<SlackDateTime>) -> Self
Returns self with updated set to the given Option.
Sourcepub fn reset_deleted(&mut self) -> &mut Self
pub fn reset_deleted(&mut self) -> &mut Self
Sets deleted to None.
Sourcepub fn mopt_deleted(&mut self, value: Option<bool>) -> &mut Self
pub fn mopt_deleted(&mut self, value: Option<bool>) -> &mut Self
Sets deleted to the given Option.
Sourcepub fn with_deleted(self, value: bool) -> Self
pub fn with_deleted(self, value: bool) -> Self
Returns self with deleted set to Some(value).
Sourcepub fn without_deleted(self) -> Self
pub fn without_deleted(self) -> Self
Returns self with deleted set to None.
Sourcepub fn opt_deleted(self, value: Option<bool>) -> Self
pub fn opt_deleted(self, value: Option<bool>) -> Self
Returns self with deleted set to the given Option.
Sourcepub fn color(&mut self, value: SlackColor) -> &mut Self
pub fn color(&mut self, value: SlackColor) -> &mut Self
Sets color to Some(value).
Sourcepub fn reset_color(&mut self) -> &mut Self
pub fn reset_color(&mut self) -> &mut Self
Sets color to None.
Sourcepub fn mopt_color(&mut self, value: Option<SlackColor>) -> &mut Self
pub fn mopt_color(&mut self, value: Option<SlackColor>) -> &mut Self
Sets color to the given Option.
Sourcepub fn with_color(self, value: SlackColor) -> Self
pub fn with_color(self, value: SlackColor) -> Self
Returns self with color set to Some(value).
Sourcepub fn without_color(self) -> Self
pub fn without_color(self) -> Self
Returns self with color set to None.
Sourcepub fn opt_color(self, value: Option<SlackColor>) -> Self
pub fn opt_color(self, value: Option<SlackColor>) -> Self
Returns self with color set to the given Option.
Sourcepub fn reset_real_name(&mut self) -> &mut Self
pub fn reset_real_name(&mut self) -> &mut Self
Sets real_name to None.
Sourcepub fn mopt_real_name(&mut self, value: Option<String>) -> &mut Self
pub fn mopt_real_name(&mut self, value: Option<String>) -> &mut Self
Sets real_name to the given Option.
Sourcepub fn with_real_name(self, value: String) -> Self
pub fn with_real_name(self, value: String) -> Self
Returns self with real_name set to Some(value).
Sourcepub fn without_real_name(self) -> Self
pub fn without_real_name(self) -> Self
Returns self with real_name set to None.
Sourcepub fn opt_real_name(self, value: Option<String>) -> Self
pub fn opt_real_name(self, value: Option<String>) -> Self
Returns self with real_name set to the given Option.
Sourcepub fn enterprise_user(&mut self, value: SlackEnterpriseUser) -> &mut Self
pub fn enterprise_user(&mut self, value: SlackEnterpriseUser) -> &mut Self
Sets enterprise_user to Some(value).
Sourcepub fn reset_enterprise_user(&mut self) -> &mut Self
pub fn reset_enterprise_user(&mut self) -> &mut Self
Sets enterprise_user to None.
Sourcepub fn mopt_enterprise_user(
&mut self,
value: Option<SlackEnterpriseUser>,
) -> &mut Self
pub fn mopt_enterprise_user( &mut self, value: Option<SlackEnterpriseUser>, ) -> &mut Self
Sets enterprise_user to the given Option.
Sourcepub fn with_enterprise_user(self, value: SlackEnterpriseUser) -> Self
pub fn with_enterprise_user(self, value: SlackEnterpriseUser) -> Self
Returns self with enterprise_user set to Some(value).
Sourcepub fn without_enterprise_user(self) -> Self
pub fn without_enterprise_user(self) -> Self
Returns self with enterprise_user set to None.
Sourcepub fn opt_enterprise_user(self, value: Option<SlackEnterpriseUser>) -> Self
pub fn opt_enterprise_user(self, value: Option<SlackEnterpriseUser>) -> Self
Returns self with enterprise_user set to the given Option.