#[non_exhaustive]pub struct CreateDnsThreatDetectorRequest {
pub parent: String,
pub dns_threat_detector_id: String,
pub dns_threat_detector: Option<DnsThreatDetector>,
/* private fields */
}Expand description
The message to create a DnsThreatDetector.
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 value for the parent of the DnsThreatDetector resource.
dns_threat_detector_id: StringOptional. The ID of the requesting DnsThreatDetector object. If this field is not supplied, the service generates an identifier.
dns_threat_detector: Option<DnsThreatDetector>Required. The DnsThreatDetector resource to create.
Implementations§
Source§impl CreateDnsThreatDetectorRequest
impl CreateDnsThreatDetectorRequest
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
Sourcepub fn set_dns_threat_detector_id<T: Into<String>>(self, v: T) -> Self
pub fn set_dns_threat_detector_id<T: Into<String>>(self, v: T) -> Self
Sets the value of dns_threat_detector_id.
§Example
ⓘ
let x = CreateDnsThreatDetectorRequest::new().set_dns_threat_detector_id("example");Sourcepub fn set_dns_threat_detector<T>(self, v: T) -> Selfwhere
T: Into<DnsThreatDetector>,
pub fn set_dns_threat_detector<T>(self, v: T) -> Selfwhere
T: Into<DnsThreatDetector>,
Sets the value of dns_threat_detector.
§Example
ⓘ
use google_cloud_networksecurity_v1::model::DnsThreatDetector;
let x = CreateDnsThreatDetectorRequest::new().set_dns_threat_detector(DnsThreatDetector::default()/* use setters */);Sourcepub fn set_or_clear_dns_threat_detector<T>(self, v: Option<T>) -> Selfwhere
T: Into<DnsThreatDetector>,
pub fn set_or_clear_dns_threat_detector<T>(self, v: Option<T>) -> Selfwhere
T: Into<DnsThreatDetector>,
Sets or clears the value of dns_threat_detector.
§Example
ⓘ
use google_cloud_networksecurity_v1::model::DnsThreatDetector;
let x = CreateDnsThreatDetectorRequest::new().set_or_clear_dns_threat_detector(Some(DnsThreatDetector::default()/* use setters */));
let x = CreateDnsThreatDetectorRequest::new().set_or_clear_dns_threat_detector(None::<DnsThreatDetector>);Trait Implementations§
Source§impl Clone for CreateDnsThreatDetectorRequest
impl Clone for CreateDnsThreatDetectorRequest
Source§fn clone(&self) -> CreateDnsThreatDetectorRequest
fn clone(&self) -> CreateDnsThreatDetectorRequest
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 Default for CreateDnsThreatDetectorRequest
impl Default for CreateDnsThreatDetectorRequest
Source§fn default() -> CreateDnsThreatDetectorRequest
fn default() -> CreateDnsThreatDetectorRequest
Returns the “default value” for a type. Read more
Source§impl PartialEq for CreateDnsThreatDetectorRequest
impl PartialEq for CreateDnsThreatDetectorRequest
Source§fn eq(&self, other: &CreateDnsThreatDetectorRequest) -> bool
fn eq(&self, other: &CreateDnsThreatDetectorRequest) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for CreateDnsThreatDetectorRequest
Auto Trait Implementations§
impl Freeze for CreateDnsThreatDetectorRequest
impl RefUnwindSafe for CreateDnsThreatDetectorRequest
impl Send for CreateDnsThreatDetectorRequest
impl Sync for CreateDnsThreatDetectorRequest
impl Unpin for CreateDnsThreatDetectorRequest
impl UnsafeUnpin for CreateDnsThreatDetectorRequest
impl UnwindSafe for CreateDnsThreatDetectorRequest
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