AWS SDK for C++

AWS SDK for C++ Version 1.11.943

Loading...
Searching...
No Matches
Citation.h
1
6#pragma once
7#include <aws/context/Context_EXPORTS.h>
8#include <aws/context/model/Reference.h>
9#include <aws/core/utils/memory/stl/AWSVector.h>
10#include <aws/crt/cbor/Cbor.h>
11
12#include <utility>
13
14namespace Aws {
15namespace Utils {
16namespace Cbor {
17class CborValue;
18} // namespace Cbor
19} // namespace Utils
20namespace Context {
21namespace Model {
22
29class Citation {
30 public:
31 AWS_CONTEXT_API Citation() = default;
32 AWS_CONTEXT_API Citation(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
33 AWS_CONTEXT_API Citation& operator=(const std::shared_ptr<Aws::Crt::Cbor::CborDecoder>& decoder);
34 AWS_CONTEXT_API void CborEncode(Aws::Crt::Cbor::CborEncoder& encoder) const;
35
37
40 inline int64_t GetStartIndex() const { return m_startIndex; }
41 inline bool StartIndexHasBeenSet() const { return m_startIndexHasBeenSet; }
42 inline void SetStartIndex(int64_t value) {
43 m_startIndexHasBeenSet = true;
44 m_startIndex = value;
45 }
46 inline Citation& WithStartIndex(int64_t value) {
47 SetStartIndex(value);
48 return *this;
49 }
51
53
57 inline int64_t GetEndIndex() const { return m_endIndex; }
58 inline bool EndIndexHasBeenSet() const { return m_endIndexHasBeenSet; }
59 inline void SetEndIndex(int64_t value) {
60 m_endIndexHasBeenSet = true;
61 m_endIndex = value;
62 }
63 inline Citation& WithEndIndex(int64_t value) {
64 SetEndIndex(value);
65 return *this;
66 }
68
70
74 inline const Aws::Vector<Reference>& GetReferences() const { return m_references; }
75 inline bool ReferencesHasBeenSet() const { return m_referencesHasBeenSet; }
76 template <typename ReferencesT = Aws::Vector<Reference>>
77 void SetReferences(ReferencesT&& value) {
78 m_referencesHasBeenSet = true;
79 m_references = std::forward<ReferencesT>(value);
80 }
81 template <typename ReferencesT = Aws::Vector<Reference>>
82 Citation& WithReferences(ReferencesT&& value) {
83 SetReferences(std::forward<ReferencesT>(value));
84 return *this;
85 }
86 template <typename ReferencesT = Reference>
87 Citation& AddReferences(ReferencesT&& value) {
88 m_referencesHasBeenSet = true;
89 m_references.emplace_back(std::forward<ReferencesT>(value));
90 return *this;
91 }
93 private:
94 int64_t m_startIndex{0};
95
96 int64_t m_endIndex{0};
97
98 Aws::Vector<Reference> m_references;
99 bool m_startIndexHasBeenSet = false;
100 bool m_endIndexHasBeenSet = false;
101 bool m_referencesHasBeenSet = false;
102};
103
104} // namespace Model
105} // namespace Context
106} // namespace Aws
AWS_CONTEXT_API Citation(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
Citation & WithReferences(ReferencesT &&value)
Definition Citation.h:82
void SetEndIndex(int64_t value)
Definition Citation.h:59
Citation & WithEndIndex(int64_t value)
Definition Citation.h:63
AWS_CONTEXT_API void CborEncode(Aws::Crt::Cbor::CborEncoder &encoder) const
int64_t GetStartIndex() const
Definition Citation.h:40
Citation & WithStartIndex(int64_t value)
Definition Citation.h:46
const Aws::Vector< Reference > & GetReferences() const
Definition Citation.h:74
void SetReferences(ReferencesT &&value)
Definition Citation.h:77
int64_t GetEndIndex() const
Definition Citation.h:57
AWS_CONTEXT_API Citation()=default
void SetStartIndex(int64_t value)
Definition Citation.h:42
Citation & AddReferences(ReferencesT &&value)
Definition Citation.h:87
AWS_CONTEXT_API Citation & operator=(const std::shared_ptr< Aws::Crt::Cbor::CborDecoder > &decoder)
bool ReferencesHasBeenSet() const
Definition Citation.h:75
bool StartIndexHasBeenSet() const
Definition Citation.h:41
bool EndIndexHasBeenSet() const
Definition Citation.h:58
std::vector< T, Aws::Allocator< T > > Vector