#[non_exhaustive]pub struct DetectorReference {
pub severity: Severity,
pub detector_id: String,
pub display_name: String,
pub explanation: String,
pub recommendation: String,
/* private fields */
}Expand description
Represents a reference to a specific anomaly detector.
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.severity: SeverityThe severity of the detector.
detector_id: StringThe unique identifier of the detector.
display_name: StringA human readable name for the detector, providing context on its purpose. For example, “ASI02: Tool Misuse”, or “Excessive API Calls”.
explanation: StringA detailed explanation generated by an LLM or the detector itself, describing why this specific anomaly was flagged. This provides rationale and context for the detection.
recommendation: StringRecommended steps or actions to remediate or investigate the anomaly flagged by this detector. These could include configuration changes, code adjustments, or further diagnostic procedures.
Implementations§
Source§impl DetectorReference
impl DetectorReference
Sourcepub fn set_severity<T: Into<Severity>>(self, v: T) -> Self
pub fn set_severity<T: Into<Severity>>(self, v: T) -> Self
Sets the value of severity.
§Example
use google_cloud_securitycenter_v2::model::detector_reference::Severity;
let x0 = DetectorReference::new().set_severity(Severity::Critical);
let x1 = DetectorReference::new().set_severity(Severity::High);
let x2 = DetectorReference::new().set_severity(Severity::Medium);Sourcepub fn set_detector_id<T: Into<String>>(self, v: T) -> Self
pub fn set_detector_id<T: Into<String>>(self, v: T) -> Self
Sets the value of detector_id.
§Example
let x = DetectorReference::new().set_detector_id("example");Sourcepub fn set_display_name<T: Into<String>>(self, v: T) -> Self
pub fn set_display_name<T: Into<String>>(self, v: T) -> Self
Sets the value of display_name.
§Example
let x = DetectorReference::new().set_display_name("example");Sourcepub fn set_explanation<T: Into<String>>(self, v: T) -> Self
pub fn set_explanation<T: Into<String>>(self, v: T) -> Self
Sets the value of explanation.
§Example
let x = DetectorReference::new().set_explanation("example");Sourcepub fn set_recommendation<T: Into<String>>(self, v: T) -> Self
pub fn set_recommendation<T: Into<String>>(self, v: T) -> Self
Sets the value of recommendation.
§Example
let x = DetectorReference::new().set_recommendation("example");Trait Implementations§
Source§impl Clone for DetectorReference
impl Clone for DetectorReference
Source§fn clone(&self) -> DetectorReference
fn clone(&self) -> DetectorReference
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for DetectorReference
impl Debug for DetectorReference
Source§impl Default for DetectorReference
impl Default for DetectorReference
Source§fn default() -> DetectorReference
fn default() -> DetectorReference
Source§impl Message for DetectorReference
impl Message for DetectorReference
Source§impl PartialEq for DetectorReference
impl PartialEq for DetectorReference
impl StructuralPartialEq for DetectorReference
Auto Trait Implementations§
impl Freeze for DetectorReference
impl RefUnwindSafe for DetectorReference
impl Send for DetectorReference
impl Sync for DetectorReference
impl Unpin for DetectorReference
impl UnsafeUnpin for DetectorReference
impl UnwindSafe for DetectorReference
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::Request