#[non_exhaustive]pub struct SetIamPolicyRequest {
pub project: String,
pub resource: String,
pub body: Option<GlobalSetPolicyRequest>,
/* private fields */
}Available on crate feature
interconnect-groups only.Expand description
Synthetic request message for the setIamPolicy() 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.project: StringProject ID for this request.
resource: StringName or id of the resource for this request.
body: Option<GlobalSetPolicyRequest>Synthetic request body field for the setIamPolicy() method.
Implementations§
Source§impl SetIamPolicyRequest
impl SetIamPolicyRequest
pub fn new() -> Self
Sourcepub fn set_project<T: Into<String>>(self, v: T) -> Self
pub fn set_project<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_resource<T: Into<String>>(self, v: T) -> Self
pub fn set_resource<T: Into<String>>(self, v: T) -> Self
Sourcepub fn set_body<T>(self, v: T) -> Selfwhere
T: Into<GlobalSetPolicyRequest>,
pub fn set_body<T>(self, v: T) -> Selfwhere
T: Into<GlobalSetPolicyRequest>,
Sourcepub fn set_or_clear_body<T>(self, v: Option<T>) -> Selfwhere
T: Into<GlobalSetPolicyRequest>,
pub fn set_or_clear_body<T>(self, v: Option<T>) -> Selfwhere
T: Into<GlobalSetPolicyRequest>,
Sets or clears the value of body.
§Example
ⓘ
use google_cloud_compute_v1::model::GlobalSetPolicyRequest;
let x = SetIamPolicyRequest::new().set_or_clear_body(Some(GlobalSetPolicyRequest::default()/* use setters */));
let x = SetIamPolicyRequest::new().set_or_clear_body(None::<GlobalSetPolicyRequest>);Trait Implementations§
Source§impl Clone for SetIamPolicyRequest
impl Clone for SetIamPolicyRequest
Source§fn clone(&self) -> SetIamPolicyRequest
fn clone(&self) -> SetIamPolicyRequest
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 SetIamPolicyRequest
impl Debug for SetIamPolicyRequest
Source§impl Default for SetIamPolicyRequest
impl Default for SetIamPolicyRequest
Source§fn default() -> SetIamPolicyRequest
fn default() -> SetIamPolicyRequest
Returns the “default value” for a type. Read more
Source§impl PartialEq for SetIamPolicyRequest
impl PartialEq for SetIamPolicyRequest
impl StructuralPartialEq for SetIamPolicyRequest
Auto Trait Implementations§
impl !Freeze for SetIamPolicyRequest
impl RefUnwindSafe for SetIamPolicyRequest
impl Send for SetIamPolicyRequest
impl Sync for SetIamPolicyRequest
impl Unpin for SetIamPolicyRequest
impl UnwindSafe for SetIamPolicyRequest
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