Struct glean_core::ping::PingMaker
source · pub struct PingMaker;
Expand description
Collect a ping’s data, assemble it into its full payload and store it on disk.
Implementations§
source§impl PingMaker
impl PingMaker
sourcepub fn collect<'a>(
&self,
glean: &Glean,
ping: &'a PingType,
reason: Option<&str>,
doc_id: &'a str,
url_path: &'a str
) -> Option<Ping<'a>>
pub fn collect<'a>( &self, glean: &Glean, ping: &'a PingType, reason: Option<&str>, doc_id: &'a str, url_path: &'a str ) -> Option<Ping<'a>>
Collects a snapshot for the given ping from storage and attach required meta information.
Arguments
glean
- theGlean
instance to collect data from.ping
- the ping to collect for.reason
- an optional reason code to include in the ping.doc_id
- the ping’s unique document identifier.url_path
- the path on the server to upload this ping to.
Returns
A fully assembled representation of the ping payload and associated metadata.
If there is no data stored for the ping, None
is returned.
Trait Implementations§
Auto Trait Implementations§
impl RefUnwindSafe for PingMaker
impl Send for PingMaker
impl Sync for PingMaker
impl Unpin for PingMaker
impl UnwindSafe for PingMaker
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
§impl<T, UT> HandleAlloc<UT> for T
impl<T, UT> HandleAlloc<UT> for T
§fn new_handle(value: Arc<T>) -> Handle
fn new_handle(value: Arc<T>) -> Handle
Create a new handle for an Arc value Read more
§unsafe fn clone_handle(handle: Handle) -> Handle
unsafe fn clone_handle(handle: Handle) -> Handle
Clone a handle Read more
§unsafe fn consume_handle(handle: Handle) -> Arc<T>
unsafe fn consume_handle(handle: Handle) -> Arc<T>
Consume a handle, getting back the initial
Arc<>
Read more