[][src]Trait reporting_api::ReportPayload

pub trait ReportPayload: 'static + Serialize + Deserialize {
    fn as_any(&self) -> &dyn Any;
fn as_debug(&self) -> &dyn Debug;
fn eq_payload(&self, other: &dyn ReportPayload) -> bool; }

Each kind of report that can be delivered via the Reporting API will have its own type, which implements this trait. Each type that implements this trait must also implement std::any::Any, std::fmt::Debug, and std::cmp::PartialEq.

Required methods

fn as_any(&self) -> &dyn Any

Returns a reference to this payload as a std::any::Any.

fn as_debug(&self) -> &dyn Debug

Returns a reference to this payload as a std::fmt::Debug.

fn eq_payload(&self, other: &dyn ReportPayload) -> bool

Compares this payload with another of an arbitrary type, returning false if the two payloads have different types.

Loading content...

Trait Implementations

impl<'typetag> Serialize for dyn ReportPayload + 'typetag[src]

impl<'typetag> Serialize for dyn ReportPayload + Send + 'typetag[src]

impl<'typetag> Serialize for dyn ReportPayload + Sync + 'typetag[src]

impl<'typetag> Serialize for dyn ReportPayload + Send + Sync + 'typetag[src]

impl Strictest for dyn ReportPayload[src]

Implementors

impl ReportPayload for NELReport[src]

Loading content...