#include <MetricEventBuilder.h>
MetricEventBuilder is a builder class responsible for building immutable MetricEvent objects.
◆ MetricEventBuilder()
alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::MetricEventBuilder |
( |
| ) |
|
◆ addDataPoint()
Adds a dataPoint object for the current metric event
- Parameters
-
dataPoint | The dataPoint object to be added to the current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
◆ addDataPoints()
MetricEventBuilder& alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::addDataPoints |
( |
const std::vector< DataPoint > & |
dataPoints | ) |
|
Adds dataPoint objects for the current metric event
- Parameters
-
dataPoints | The shared ptrs to dataPoints to be added to the current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
◆ build()
std::shared_ptr<MetricEvent> alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::build |
( |
| ) |
|
◆ clear()
void alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::clear |
( |
| ) |
|
Clears all member variables to the default state
◆ generateKey()
static std::string alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::generateKey |
( |
const std::string & |
name, |
|
|
DataType |
dataType |
|
) |
| |
|
static |
Public static method to generate dataPoint key This is needed to provide a consistent way of generating DataPoint objects' keys.
- Returns
- the key to the dataPoint
◆ removeDataPoint() [1/2]
Removes a dataPoint object from the current metric event
- Parameters
-
dataPoint | The dataPoint object to be removed from the current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
◆ removeDataPoint() [2/2]
MetricEventBuilder& alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::removeDataPoint |
( |
const std::string & |
name, |
|
|
DataType |
dataType |
|
) |
| |
Removes a dataPoint object from the current metric event
- Parameters
-
name | The name of the dataPoint to be removed from the current metric event |
dataType | The datatype of the dataPoint to be removed from the current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
◆ removeDataPoints()
MetricEventBuilder& alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::removeDataPoints |
( |
| ) |
|
Removes all dataPoint objects from the current metric event
- Returns
- This instance to facilitate adding more information to this metric event.
◆ setActivityName()
MetricEventBuilder& alexaClientSDK::avsCommon::utils::metrics::MetricEventBuilder::setActivityName |
( |
const std::string & |
activityName | ) |
|
Sets the activity name for the current metric event
- Parameters
-
activityName | The activity name of the current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
◆ setPriority()
Sets the priority for the current metric event
- Parameters
-
priority | The priority of current metric event |
- Returns
- This instance to facilitate adding more information to this metric event.
The documentation for this class was generated from the following file:
AlexaClientSDK 3.0.0 - Copyright 2016-2022 Amazon.com, Inc. or its affiliates. All Rights Reserved.
Licensed under the Apache License, Version 2.0