AlexaClientSDK  3.0.0
A cross-platform, modular SDK for interacting with the Alexa Voice Service
Public Member Functions | List of all members
alexaClientSDK::avsCommon::utils::metrics::DataPointCounterBuilder Class Reference

#include <DataPointCounterBuilder.h>

Public Member Functions

 DataPointCounterBuilder ()
 
DataPointCounterBuildersetName (const std::string &name)
 
DataPointCounterBuilderincrement (uint64_t toAdd)
 
DataPoint build ()
 

Detailed Description

DataPointCounterBuilder is a builder class responsible for building immutable counter DataPoint objects.

The range of values supported by DataPointCounterBuilder ranges from 0 to 2^64. When DataPointCounterBuilder is first initialized the default value is 0.

Constructor & Destructor Documentation

◆ DataPointCounterBuilder()

alexaClientSDK::avsCommon::utils::metrics::DataPointCounterBuilder::DataPointCounterBuilder ( )

Constructor

Member Function Documentation

◆ build()

DataPoint alexaClientSDK::avsCommon::utils::metrics::DataPointCounterBuilder::build ( )

Builds a new immutable DataPoint object with the current state stored in dataPoint counter builder.

Returns
A new immutable DataPoint object

◆ increment()

DataPointCounterBuilder& alexaClientSDK::avsCommon::utils::metrics::DataPointCounterBuilder::increment ( uint64_t  toAdd)

Increments the value of the counter dataPoint If an overflow should occur, the value will be set to the maximum value of uint64_t, 2^64.

Parameters
toAddThe value to be added to the counter dataPoint.
Returns
This instance to facilitate setting more information to this dataPoint counter builder.

◆ setName()

DataPointCounterBuilder& alexaClientSDK::avsCommon::utils::metrics::DataPointCounterBuilder::setName ( const std::string &  name)

Sets the name of the counter dataPoint

Parameters
nameThe name of the counter dataPoint.
Returns
This instance to facilitate setting more information to this dataPoint counter builder.

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