Struct clean_insights_sdk::insights::Insights
source · [−]pub struct Insights {
pub idsite: u32,
pub lang: Option<String>,
pub ua: Option<String>,
pub visits: Vec<Visit>,
pub events: Vec<Event>,
}
Fields
idsite: u32
Matomo site ID.
lang: Option<String>
Preferred user languages as an HTTP Accept header.
ua: Option<String>
User Agent string.
visits: Vec<Visit>
Visit
data points.
events: Vec<Event>
Event
data points.
Implementations
sourceimpl Insights
impl Insights
sourcepub fn new(
conf: &Configuration,
store: &mut dyn Store,
lang: &Vec<String>,
ua: &Option<String>
) -> Insights
pub fn new(
conf: &Configuration,
store: &mut dyn Store,
lang: &Vec<String>,
ua: &Option<String>
) -> Insights
Create an Insights
object according to configuration with all data from the store which is
due for offloading to the server.
Arguments
- conf: The current configuration.
- store: The current measurement and consents store.
- lang: User languages in order of preference.
- ua: User Agent string.
pub fn is_empty(&self) -> bool
Trait Implementations
sourceimpl<'de> Deserialize<'de> for Insights
impl<'de> Deserialize<'de> for Insights
sourcefn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error> where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations
impl RefUnwindSafe for Insights
impl Send for Insights
impl Sync for Insights
impl Unpin for Insights
impl UnwindSafe for Insights
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcepub fn borrow_mut(&mut self) -> &mut T
pub fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more