AWS SDK for C++

AWS SDK for C++ Version 1.11.440

Loading...
Searching...
No Matches
TraceSpan.h
1
5#pragma once
6
7#include <aws/core/utils/memory/stl/AWSString.h>
8#include <aws/core/utils/memory/stl/AWSMap.h>
9#include <smithy/Smithy_EXPORTS.h>
10#include <memory>
11#include <utility>
12
13namespace smithy {
14 namespace components {
15 namespace tracing {
19 enum class TraceSpanStatus {
20 UNSET,
21 OK,
22 FAULT,
23 };
24
30 class SMITHY_API TraceSpan {
31 public:
36 TraceSpan(Aws::String name) : m_name(std::move(name)) {}
37
38 virtual ~TraceSpan() = default;
39
45 virtual void emitEvent(Aws::String name, const Aws::Map<Aws::String, Aws::String> &attributes) = 0;
46
52 virtual void setAttribute(Aws::String key, Aws::String value) = 0;
53
58 virtual void setStatus(TraceSpanStatus status) = 0;
59
63 virtual void end() = 0;
64
65 private:
66 Aws::String m_name;
67 };
68 }
69 }
70}
virtual void setAttribute(Aws::String key, Aws::String value)=0
virtual void setStatus(TraceSpanStatus status)=0
virtual void emitEvent(Aws::String name, const Aws::Map< Aws::String, Aws::String > &attributes)=0
std::map< K, V, std::less< K >, Aws::Allocator< std::pair< const K, V > > > Map
Definition AWSMap.h:20
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Definition AWSString.h:97