pub enum Event {
Metric(Metric),
EventD(EventD),
ServiceCheck(ServiceCheck),
Log(Log),
Trace(Trace),
TraceStats(TraceStats),
}Expand description
A telemetry event.
Variants§
Metric(Metric)
A metric.
EventD(EventD)
A Datadog Event.
ServiceCheck(ServiceCheck)
A service check.
Log(Log)
A log.
Trace(Trace)
A trace.
TraceStats(TraceStats)
Trace stats.
Implementations§
Source§impl Event
impl Event
Sourcepub fn event_type(&self) -> EventType
pub fn event_type(&self) -> EventType
Gets the type of this event.
Sourcepub fn try_into_metric(self) -> Option<Metric>
pub fn try_into_metric(self) -> Option<Metric>
Returns the inner event value, if this event is a Metric.
Otherwise, None is returned and the original event is consumed.
Sourcepub fn try_as_metric(&self) -> Option<&Metric>
pub fn try_as_metric(&self) -> Option<&Metric>
Returns a reference inner event value, if this event is a Metric.
Otherwise, None is returned.
Sourcepub fn try_as_metric_mut(&mut self) -> Option<&mut Metric>
pub fn try_as_metric_mut(&mut self) -> Option<&mut Metric>
Returns a mutable reference inner event value, if this event is a Metric.
Otherwise, None is returned.
Sourcepub fn try_into_eventd(self) -> Option<EventD>
pub fn try_into_eventd(self) -> Option<EventD>
Returns the inner event value, if this event is a EventD.
Otherwise, None is returned and the original event is consumed.
Sourcepub fn try_into_service_check(self) -> Option<ServiceCheck>
pub fn try_into_service_check(self) -> Option<ServiceCheck>
Returns the inner event value, if this event is a ServiceCheck.
Otherwise, None is returned and the original event is consumed.
Sourcepub fn try_into_trace(self) -> Option<Trace>
pub fn try_into_trace(self) -> Option<Trace>
Returns a reference inner event value, if this event is a Trace.
Otherwise, None is returned.
Sourcepub fn try_as_trace_mut(&mut self) -> Option<&mut Trace>
pub fn try_as_trace_mut(&mut self) -> Option<&mut Trace>
Returns a mutable reference inner event value, if this event is a Trace.
Otherwise, None is returned.
Sourcepub fn try_into_trace_stats(self) -> Option<TraceStats>
pub fn try_into_trace_stats(self) -> Option<TraceStats>
Returns the inner event value, if this event is a TraceStats.
Otherwise, None is returned and the original event is consumed.
Sourcepub fn is_service_check(&self) -> bool
pub fn is_service_check(&self) -> bool
Returns true if the event is a service check.
Trait Implementations§
impl StructuralPartialEq for Event
Auto Trait Implementations§
impl Freeze for Event
impl !RefUnwindSafe for Event
impl Send for Event
impl Sync for Event
impl Unpin for Event
impl !UnwindSafe for Event
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
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::RequestSource§impl<T> Pointable for T
impl<T> Pointable for T
§impl<T> Track for T
impl<T> Track for T
§fn track_allocations(self, token: AllocationGroupToken) -> Tracked<Self>
fn track_allocations(self, token: AllocationGroupToken) -> Tracked<Self>
Tracked wrapper. Read more§fn in_current_allocation_group(self) -> Tracked<Self>
fn in_current_allocation_group(self) -> Tracked<Self>
Tracked wrapper. Read more