#[non_exhaustive]pub struct CreateDataPolicyRequest {
pub parent: String,
pub data_policy_id: String,
pub data_policy: Option<DataPolicy>,
/* private fields */
}Expand description
Request message for the CreateDataPolicy 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. Resource name of the project that the data policy will belong to.
The format is projects/{project_number}/locations/{location_id}.
data_policy_id: StringRequired. User-assigned (human readable) ID of the data policy that needs to be unique within a project. Used as {data_policy_id} in part of the resource name.
data_policy: Option<DataPolicy>Required. The data policy to create. The name field does not need to be
provided for the data policy creation.
Implementations§
Source§impl CreateDataPolicyRequest
impl CreateDataPolicyRequest
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_data_policy_id<T: Into<String>>(self, v: T) -> Self
pub fn set_data_policy_id<T: Into<String>>(self, v: T) -> Self
Sets the value of data_policy_id.
Sourcepub fn set_data_policy<T>(self, v: T) -> Selfwhere
T: Into<DataPolicy>,
pub fn set_data_policy<T>(self, v: T) -> Selfwhere
T: Into<DataPolicy>,
Sets the value of data_policy.
Sourcepub fn set_or_clear_data_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<DataPolicy>,
pub fn set_or_clear_data_policy<T>(self, v: Option<T>) -> Selfwhere
T: Into<DataPolicy>,
Sets or clears the value of data_policy.
Trait Implementations§
Source§impl Clone for CreateDataPolicyRequest
impl Clone for CreateDataPolicyRequest
Source§fn clone(&self) -> CreateDataPolicyRequest
fn clone(&self) -> CreateDataPolicyRequest
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 CreateDataPolicyRequest
impl Debug for CreateDataPolicyRequest
Source§impl Default for CreateDataPolicyRequest
impl Default for CreateDataPolicyRequest
Source§fn default() -> CreateDataPolicyRequest
fn default() -> CreateDataPolicyRequest
Returns the “default value” for a type. Read more
Source§impl Message for CreateDataPolicyRequest
impl Message for CreateDataPolicyRequest
Source§impl PartialEq for CreateDataPolicyRequest
impl PartialEq for CreateDataPolicyRequest
impl StructuralPartialEq for CreateDataPolicyRequest
Auto Trait Implementations§
impl Freeze for CreateDataPolicyRequest
impl RefUnwindSafe for CreateDataPolicyRequest
impl Send for CreateDataPolicyRequest
impl Sync for CreateDataPolicyRequest
impl Unpin for CreateDataPolicyRequest
impl UnwindSafe for CreateDataPolicyRequest
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