Metrics event is used to represent one event which contains a collection of metrics attributes.
More...
#include <MetricsEvent.h>
Metrics event is used to represent one event which contains a collection of metrics attributes.
◆ AddAttribute()
void AWSMetrics::MetricsEvent::AddAttribute |
( |
const MetricsAttribute & |
attribute | ) |
|
Add a new attribute to the metrics.
- Parameters
-
attribute | Attribute to add. |
◆ AddAttributes()
void AWSMetrics::MetricsEvent::AddAttributes |
( |
const AZStd::vector< MetricsAttribute > & |
attributes | ) |
|
Add attributes to the metrics event.
- Parameters
-
attributes | List of attributes to append. |
◆ GetEventPriority()
int AWSMetrics::MetricsEvent::GetEventPriority |
( |
| ) |
const |
Get the priority of the metrics event.
- Returns
- Priority of the metrics event.
◆ GetNumFailures()
int AWSMetrics::MetricsEvent::GetNumFailures |
( |
| ) |
const |
Get the count of failures for sending the metrics event.
- Returns
- Count of failures for sending the metrics event.
◆ GetSizeInBytes()
size_t AWSMetrics::MetricsEvent::GetSizeInBytes |
( |
| ) |
const |
Get the metrics event size serialized to json.
- Returns
- metrics event size in bytes.
◆ ReadFromJson()
bool AWSMetrics::MetricsEvent::ReadFromJson |
( |
rapidjson::Value & |
metricsObjVal | ) |
|
Read from a JSON value to the metrics event.
- Parameters
-
metricsObjVal | JSON value to read from. |
- Returns
- Whether the metrics event is created successfully.
◆ SerializeToJson()
bool AWSMetrics::MetricsEvent::SerializeToJson |
( |
AWSCore::JsonWriter & |
writer | ) |
const |
Serialize the metrics event to JSON for the sending requests.
- Parameters
-
writer | JSON writer for the serialization. |
- Returns
- Whether the metrics event is serialized successfully.
◆ SetEventPriority()
void AWSMetrics::MetricsEvent::SetEventPriority |
( |
int |
priority | ) |
|
Set the priority of a metrics event.
- Parameters
-
◆ ValidateAgainstSchema()
bool AWSMetrics::MetricsEvent::ValidateAgainstSchema |
( |
| ) |
|
Validate the metrics event with the predefined JSON schema.
- Returns
- whether the metrics event match the JSON schema.
The documentation for this class was generated from the following file:
- Gems/AWSMetrics/Code/Source/MetricsEvent.h