#[non_exhaustive]pub struct CreateEnrollmentRequest {
pub parent: String,
pub enrollment: Option<Enrollment>,
pub enrollment_id: String,
pub validate_only: bool,
/* private fields */
}Expand description
The request message for the CreateEnrollment method.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Non-exhaustive structs could have additional fields added in future. Therefore, non-exhaustive structs cannot be constructed in external crates using the traditional
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.parent: StringRequired. The parent collection in which to add this enrollment.
enrollment: Option<Enrollment>Required. The enrollment to create.
enrollment_id: StringRequired. The user-provided ID to be assigned to the Enrollment. It should
match the format ^[a-z]([a-z0-9-]{0,61}[a-z0-9])?$.
validate_only: boolOptional. If set, validate the request and preview the review, but do not post it.
Implementations§
Source§impl CreateEnrollmentRequest
impl CreateEnrollmentRequest
pub fn new() -> Self
Sourcepub fn set_parent<T: Into<String>>(self, v: T) -> Self
pub fn set_parent<T: Into<String>>(self, v: T) -> Self
Sets the value of parent.
Sourcepub fn set_enrollment<T>(self, v: T) -> Selfwhere
T: Into<Enrollment>,
pub fn set_enrollment<T>(self, v: T) -> Selfwhere
T: Into<Enrollment>,
Sets the value of enrollment.
Sourcepub fn set_or_clear_enrollment<T>(self, v: Option<T>) -> Selfwhere
T: Into<Enrollment>,
pub fn set_or_clear_enrollment<T>(self, v: Option<T>) -> Selfwhere
T: Into<Enrollment>,
Sets or clears the value of enrollment.
Sourcepub fn set_enrollment_id<T: Into<String>>(self, v: T) -> Self
pub fn set_enrollment_id<T: Into<String>>(self, v: T) -> Self
Sets the value of enrollment_id.
Sourcepub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
pub fn set_validate_only<T: Into<bool>>(self, v: T) -> Self
Sets the value of validate_only.
Trait Implementations§
Source§impl Clone for CreateEnrollmentRequest
impl Clone for CreateEnrollmentRequest
Source§fn clone(&self) -> CreateEnrollmentRequest
fn clone(&self) -> CreateEnrollmentRequest
Returns a duplicate 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 Debug for CreateEnrollmentRequest
impl Debug for CreateEnrollmentRequest
Source§impl Default for CreateEnrollmentRequest
impl Default for CreateEnrollmentRequest
Source§fn default() -> CreateEnrollmentRequest
fn default() -> CreateEnrollmentRequest
Returns the “default value” for a type. Read more
Source§impl Message for CreateEnrollmentRequest
impl Message for CreateEnrollmentRequest
Source§impl PartialEq for CreateEnrollmentRequest
impl PartialEq for CreateEnrollmentRequest
impl StructuralPartialEq for CreateEnrollmentRequest
Auto Trait Implementations§
impl Freeze for CreateEnrollmentRequest
impl RefUnwindSafe for CreateEnrollmentRequest
impl Send for CreateEnrollmentRequest
impl Sync for CreateEnrollmentRequest
impl Unpin for CreateEnrollmentRequest
impl UnwindSafe for CreateEnrollmentRequest
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