#[non_exhaustive]pub struct UserLicense {
pub user_principal: String,
pub user_profile: String,
pub license_assignment_state: LicenseAssignmentState,
pub license_config: String,
pub create_time: Option<Timestamp>,
pub update_time: Option<Timestamp>,
pub last_login_time: Option<Timestamp>,
/* private fields */
}user-license-service only.Expand description
User License information assigned by the admin.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.user_principal: StringRequired. Immutable. The user principal of the User, could be email address or other prinical identifier. This field is immutable. Admin assign licenses based on the user principal.
user_profile: StringOptional. The user profile. We user user full name(First name + Last name) as user profile.
license_assignment_state: LicenseAssignmentStateOutput only. License assignment state of the user. If the user is assigned with a license config, the user loggin will be assigned with the license; If the user’s license assignment state is unassigned or unspecified, no license config will be associated to the user;
license_config: StringOptional. The full resource name of the Subscription(LicenseConfig) assigned to the user.
create_time: Option<Timestamp>Output only. User created timestamp.
update_time: Option<Timestamp>Output only. User update timestamp.
last_login_time: Option<Timestamp>Output only. User last logged in time. If the user has not logged in yet, this field will be empty.
Implementations§
Source§impl UserLicense
impl UserLicense
pub fn new() -> Self
Sourcepub fn set_user_principal<T: Into<String>>(self, v: T) -> Self
pub fn set_user_principal<T: Into<String>>(self, v: T) -> Self
Sets the value of user_principal.
§Example
let x = UserLicense::new().set_user_principal("example");Sourcepub fn set_user_profile<T: Into<String>>(self, v: T) -> Self
pub fn set_user_profile<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_license_assignment_state<T: Into<LicenseAssignmentState>>(
self,
v: T,
) -> Self
pub fn set_license_assignment_state<T: Into<LicenseAssignmentState>>( self, v: T, ) -> Self
Sets the value of license_assignment_state.
§Example
use google_cloud_discoveryengine_v1::model::user_license::LicenseAssignmentState;
let x0 = UserLicense::new().set_license_assignment_state(LicenseAssignmentState::Assigned);
let x1 = UserLicense::new().set_license_assignment_state(LicenseAssignmentState::Unassigned);
let x2 = UserLicense::new().set_license_assignment_state(LicenseAssignmentState::NoLicense);Sourcepub fn set_license_config<T: Into<String>>(self, v: T) -> Self
pub fn set_license_config<T: Into<String>>(self, v: T) -> Self
Sets the value of license_config.
§Example
let x = UserLicense::new().set_license_config("example");Sourcepub fn set_create_time<T>(self, v: T) -> Self
pub fn set_create_time<T>(self, v: T) -> Self
Sets the value of create_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_create_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_create_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of create_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_or_clear_create_time(Some(Timestamp::default()/* use setters */));
let x = UserLicense::new().set_or_clear_create_time(None::<Timestamp>);Sourcepub fn set_update_time<T>(self, v: T) -> Self
pub fn set_update_time<T>(self, v: T) -> Self
Sets the value of update_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_update_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_update_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of update_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_or_clear_update_time(Some(Timestamp::default()/* use setters */));
let x = UserLicense::new().set_or_clear_update_time(None::<Timestamp>);Sourcepub fn set_last_login_time<T>(self, v: T) -> Self
pub fn set_last_login_time<T>(self, v: T) -> Self
Sets the value of last_login_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_last_login_time(Timestamp::default()/* use setters */);Sourcepub fn set_or_clear_last_login_time<T>(self, v: Option<T>) -> Self
pub fn set_or_clear_last_login_time<T>(self, v: Option<T>) -> Self
Sets or clears the value of last_login_time.
§Example
use wkt::Timestamp;
let x = UserLicense::new().set_or_clear_last_login_time(Some(Timestamp::default()/* use setters */));
let x = UserLicense::new().set_or_clear_last_login_time(None::<Timestamp>);Trait Implementations§
Source§impl Clone for UserLicense
impl Clone for UserLicense
Source§fn clone(&self) -> UserLicense
fn clone(&self) -> UserLicense
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more