![]() |
AlexaClientSDK
3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
|
#include <MetricEvent.h>
Public Member Functions | |
MetricEvent (const std::string &activityName, Priority priority, const std::unordered_map< std::string, DataPoint > &dataPoints, std::chrono::steady_clock::time_point timestamp) | |
std::string | getActivityName () const |
Priority | getPriority () const |
Optional< DataPoint > | getDataPoint (const std::string &name, DataType dataType) const |
std::vector< DataPoint > | getDataPoints () const |
std::chrono::system_clock::time_point | getTimestamp () const |
std::chrono::steady_clock::time_point | getSteadyTimestamp () const |
This class represents the immutable MetricEvent object.
alexaClientSDK::avsCommon::utils::metrics::MetricEvent::MetricEvent | ( | const std::string & | activityName, |
Priority | priority, | ||
const std::unordered_map< std::string, DataPoint > & | dataPoints, | ||
std::chrono::steady_clock::time_point | timestamp | ||
) |
Constructor
activityName | is the activity name of the metric event. |
priority | is the priority of the metric event |
dataPoints | is the collection of key value pairs from dataPoint id to dataPoint objects |
timestamp | is the timestamp at which this metric event was created. |
std::string alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getActivityName | ( | ) | const |
Getter method for the activity name of the metric event
Optional<DataPoint> alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getDataPoint | ( | const std::string & | name, |
DataType | dataType | ||
) | const |
Gets dataPoint object from the current metric event
name | The name of the dataPoint to be retrieved |
dataType | The dataType of the dataPoint to be retrieved |
std::vector<DataPoint> alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getDataPoints | ( | ) | const |
Getter method for the dataPoints of the metric event
Priority alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getPriority | ( | ) | const |
Getter method for the priority of the metric event
std::chrono::steady_clock::time_point alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getSteadyTimestamp | ( | ) | const |
Getter method for the timestamp of when the metric event was created as a steady clock time point.
std::chrono::system_clock::time_point alexaClientSDK::avsCommon::utils::metrics::MetricEvent::getTimestamp | ( | ) | const |
Getter method for the timestamp of when the metric event was created as a system clock time point.
AlexaClientSDK 3.0.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved. Licensed under the Apache License, Version 2.0