/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include namespace Aws { namespace Utils { namespace Json { class JsonValue; class JsonView; } // namespace Json } // namespace Utils namespace Shield { namespace Model { /** *

The counter that describes a DDoS attack.

See Also:

AWS * API Reference

*/ class SummarizedCounter { public: AWS_SHIELD_API SummarizedCounter(); AWS_SHIELD_API SummarizedCounter(Aws::Utils::Json::JsonView jsonValue); AWS_SHIELD_API SummarizedCounter& operator=(Aws::Utils::Json::JsonView jsonValue); AWS_SHIELD_API Aws::Utils::Json::JsonValue Jsonize() const; /** *

The counter name.

*/ inline const Aws::String& GetName() const{ return m_name; } /** *

The counter name.

*/ inline bool NameHasBeenSet() const { return m_nameHasBeenSet; } /** *

The counter name.

*/ inline void SetName(const Aws::String& value) { m_nameHasBeenSet = true; m_name = value; } /** *

The counter name.

*/ inline void SetName(Aws::String&& value) { m_nameHasBeenSet = true; m_name = std::move(value); } /** *

The counter name.

*/ inline void SetName(const char* value) { m_nameHasBeenSet = true; m_name.assign(value); } /** *

The counter name.

*/ inline SummarizedCounter& WithName(const Aws::String& value) { SetName(value); return *this;} /** *

The counter name.

*/ inline SummarizedCounter& WithName(Aws::String&& value) { SetName(std::move(value)); return *this;} /** *

The counter name.

*/ inline SummarizedCounter& WithName(const char* value) { SetName(value); return *this;} /** *

The maximum value of the counter for a specified time period.

*/ inline double GetMax() const{ return m_max; } /** *

The maximum value of the counter for a specified time period.

*/ inline bool MaxHasBeenSet() const { return m_maxHasBeenSet; } /** *

The maximum value of the counter for a specified time period.

*/ inline void SetMax(double value) { m_maxHasBeenSet = true; m_max = value; } /** *

The maximum value of the counter for a specified time period.

*/ inline SummarizedCounter& WithMax(double value) { SetMax(value); return *this;} /** *

The average value of the counter for a specified time period.

*/ inline double GetAverage() const{ return m_average; } /** *

The average value of the counter for a specified time period.

*/ inline bool AverageHasBeenSet() const { return m_averageHasBeenSet; } /** *

The average value of the counter for a specified time period.

*/ inline void SetAverage(double value) { m_averageHasBeenSet = true; m_average = value; } /** *

The average value of the counter for a specified time period.

*/ inline SummarizedCounter& WithAverage(double value) { SetAverage(value); return *this;} /** *

The total of counter values for a specified time period.

*/ inline double GetSum() const{ return m_sum; } /** *

The total of counter values for a specified time period.

*/ inline bool SumHasBeenSet() const { return m_sumHasBeenSet; } /** *

The total of counter values for a specified time period.

*/ inline void SetSum(double value) { m_sumHasBeenSet = true; m_sum = value; } /** *

The total of counter values for a specified time period.

*/ inline SummarizedCounter& WithSum(double value) { SetSum(value); return *this;} /** *

The number of counters for a specified time period.

*/ inline int GetN() const{ return m_n; } /** *

The number of counters for a specified time period.

*/ inline bool NHasBeenSet() const { return m_nHasBeenSet; } /** *

The number of counters for a specified time period.

*/ inline void SetN(int value) { m_nHasBeenSet = true; m_n = value; } /** *

The number of counters for a specified time period.

*/ inline SummarizedCounter& WithN(int value) { SetN(value); return *this;} /** *

The unit of the counters.

*/ inline const Aws::String& GetUnit() const{ return m_unit; } /** *

The unit of the counters.

*/ inline bool UnitHasBeenSet() const { return m_unitHasBeenSet; } /** *

The unit of the counters.

*/ inline void SetUnit(const Aws::String& value) { m_unitHasBeenSet = true; m_unit = value; } /** *

The unit of the counters.

*/ inline void SetUnit(Aws::String&& value) { m_unitHasBeenSet = true; m_unit = std::move(value); } /** *

The unit of the counters.

*/ inline void SetUnit(const char* value) { m_unitHasBeenSet = true; m_unit.assign(value); } /** *

The unit of the counters.

*/ inline SummarizedCounter& WithUnit(const Aws::String& value) { SetUnit(value); return *this;} /** *

The unit of the counters.

*/ inline SummarizedCounter& WithUnit(Aws::String&& value) { SetUnit(std::move(value)); return *this;} /** *

The unit of the counters.

*/ inline SummarizedCounter& WithUnit(const char* value) { SetUnit(value); return *this;} private: Aws::String m_name; bool m_nameHasBeenSet = false; double m_max; bool m_maxHasBeenSet = false; double m_average; bool m_averageHasBeenSet = false; double m_sum; bool m_sumHasBeenSet = false; int m_n; bool m_nHasBeenSet = false; Aws::String m_unit; bool m_unitHasBeenSet = false; }; } // namespace Model } // namespace Shield } // namespace Aws