AWS SDK for C++

AWS SDK for C++ Version 1.11.719

Loading...
Searching...
No Matches
Transaction.h
1
6#pragma once
7#include <aws/core/utils/DateTime.h>
8#include <aws/core/utils/memory/stl/AWSString.h>
9#include <aws/managedblockchain-query/ManagedBlockchainQuery_EXPORTS.h>
10#include <aws/managedblockchain-query/model/ConfirmationStatus.h>
11#include <aws/managedblockchain-query/model/ExecutionStatus.h>
12#include <aws/managedblockchain-query/model/QueryNetwork.h>
13
14#include <utility>
15
16namespace Aws {
17namespace Utils {
18namespace Json {
19class JsonValue;
20class JsonView;
21} // namespace Json
22} // namespace Utils
23namespace ManagedBlockchainQuery {
24namespace Model {
25
38 public:
39 AWS_MANAGEDBLOCKCHAINQUERY_API Transaction() = default;
40 AWS_MANAGEDBLOCKCHAINQUERY_API Transaction(Aws::Utils::Json::JsonView jsonValue);
41 AWS_MANAGEDBLOCKCHAINQUERY_API Transaction& operator=(Aws::Utils::Json::JsonView jsonValue);
42 AWS_MANAGEDBLOCKCHAINQUERY_API Aws::Utils::Json::JsonValue Jsonize() const;
43
45
48 inline QueryNetwork GetNetwork() const { return m_network; }
49 inline bool NetworkHasBeenSet() const { return m_networkHasBeenSet; }
50 inline void SetNetwork(QueryNetwork value) {
51 m_networkHasBeenSet = true;
52 m_network = value;
53 }
55 SetNetwork(value);
56 return *this;
57 }
59
61
66 inline const Aws::String& GetBlockHash() const { return m_blockHash; }
67 inline bool BlockHashHasBeenSet() const { return m_blockHashHasBeenSet; }
68 template <typename BlockHashT = Aws::String>
69 void SetBlockHash(BlockHashT&& value) {
70 m_blockHashHasBeenSet = true;
71 m_blockHash = std::forward<BlockHashT>(value);
72 }
73 template <typename BlockHashT = Aws::String>
74 Transaction& WithBlockHash(BlockHashT&& value) {
75 SetBlockHash(std::forward<BlockHashT>(value));
76 return *this;
77 }
79
81
84 inline const Aws::String& GetTransactionHash() const { return m_transactionHash; }
85 inline bool TransactionHashHasBeenSet() const { return m_transactionHashHasBeenSet; }
86 template <typename TransactionHashT = Aws::String>
87 void SetTransactionHash(TransactionHashT&& value) {
88 m_transactionHashHasBeenSet = true;
89 m_transactionHash = std::forward<TransactionHashT>(value);
90 }
91 template <typename TransactionHashT = Aws::String>
92 Transaction& WithTransactionHash(TransactionHashT&& value) {
93 SetTransactionHash(std::forward<TransactionHashT>(value));
94 return *this;
95 }
97
99
102 inline const Aws::String& GetBlockNumber() const { return m_blockNumber; }
103 inline bool BlockNumberHasBeenSet() const { return m_blockNumberHasBeenSet; }
104 template <typename BlockNumberT = Aws::String>
105 void SetBlockNumber(BlockNumberT&& value) {
106 m_blockNumberHasBeenSet = true;
107 m_blockNumber = std::forward<BlockNumberT>(value);
108 }
109 template <typename BlockNumberT = Aws::String>
110 Transaction& WithBlockNumber(BlockNumberT&& value) {
111 SetBlockNumber(std::forward<BlockNumberT>(value));
112 return *this;
113 }
115
117
120 inline const Aws::Utils::DateTime& GetTransactionTimestamp() const { return m_transactionTimestamp; }
121 inline bool TransactionTimestampHasBeenSet() const { return m_transactionTimestampHasBeenSet; }
122 template <typename TransactionTimestampT = Aws::Utils::DateTime>
123 void SetTransactionTimestamp(TransactionTimestampT&& value) {
124 m_transactionTimestampHasBeenSet = true;
125 m_transactionTimestamp = std::forward<TransactionTimestampT>(value);
126 }
127 template <typename TransactionTimestampT = Aws::Utils::DateTime>
128 Transaction& WithTransactionTimestamp(TransactionTimestampT&& value) {
129 SetTransactionTimestamp(std::forward<TransactionTimestampT>(value));
130 return *this;
131 }
133
135
138 inline long long GetTransactionIndex() const { return m_transactionIndex; }
139 inline bool TransactionIndexHasBeenSet() const { return m_transactionIndexHasBeenSet; }
140 inline void SetTransactionIndex(long long value) {
141 m_transactionIndexHasBeenSet = true;
142 m_transactionIndex = value;
143 }
144 inline Transaction& WithTransactionIndex(long long value) {
145 SetTransactionIndex(value);
146 return *this;
147 }
149
151
154 inline long long GetNumberOfTransactions() const { return m_numberOfTransactions; }
155 inline bool NumberOfTransactionsHasBeenSet() const { return m_numberOfTransactionsHasBeenSet; }
156 inline void SetNumberOfTransactions(long long value) {
157 m_numberOfTransactionsHasBeenSet = true;
158 m_numberOfTransactions = value;
159 }
160 inline Transaction& WithNumberOfTransactions(long long value) {
162 return *this;
163 }
165
167
171 inline const Aws::String& GetTo() const { return m_to; }
172 inline bool ToHasBeenSet() const { return m_toHasBeenSet; }
173 template <typename ToT = Aws::String>
174 void SetTo(ToT&& value) {
175 m_toHasBeenSet = true;
176 m_to = std::forward<ToT>(value);
177 }
178 template <typename ToT = Aws::String>
179 Transaction& WithTo(ToT&& value) {
180 SetTo(std::forward<ToT>(value));
181 return *this;
182 }
184
186
190 inline const Aws::String& GetFrom() const { return m_from; }
191 inline bool FromHasBeenSet() const { return m_fromHasBeenSet; }
192 template <typename FromT = Aws::String>
193 void SetFrom(FromT&& value) {
194 m_fromHasBeenSet = true;
195 m_from = std::forward<FromT>(value);
196 }
197 template <typename FromT = Aws::String>
198 Transaction& WithFrom(FromT&& value) {
199 SetFrom(std::forward<FromT>(value));
200 return *this;
201 }
203
205
208 inline const Aws::String& GetContractAddress() const { return m_contractAddress; }
209 inline bool ContractAddressHasBeenSet() const { return m_contractAddressHasBeenSet; }
210 template <typename ContractAddressT = Aws::String>
211 void SetContractAddress(ContractAddressT&& value) {
212 m_contractAddressHasBeenSet = true;
213 m_contractAddress = std::forward<ContractAddressT>(value);
214 }
215 template <typename ContractAddressT = Aws::String>
216 Transaction& WithContractAddress(ContractAddressT&& value) {
217 SetContractAddress(std::forward<ContractAddressT>(value));
218 return *this;
219 }
221
223
226 inline const Aws::String& GetGasUsed() const { return m_gasUsed; }
227 inline bool GasUsedHasBeenSet() const { return m_gasUsedHasBeenSet; }
228 template <typename GasUsedT = Aws::String>
229 void SetGasUsed(GasUsedT&& value) {
230 m_gasUsedHasBeenSet = true;
231 m_gasUsed = std::forward<GasUsedT>(value);
232 }
233 template <typename GasUsedT = Aws::String>
234 Transaction& WithGasUsed(GasUsedT&& value) {
235 SetGasUsed(std::forward<GasUsedT>(value));
236 return *this;
237 }
239
241
244 inline const Aws::String& GetCumulativeGasUsed() const { return m_cumulativeGasUsed; }
245 inline bool CumulativeGasUsedHasBeenSet() const { return m_cumulativeGasUsedHasBeenSet; }
246 template <typename CumulativeGasUsedT = Aws::String>
247 void SetCumulativeGasUsed(CumulativeGasUsedT&& value) {
248 m_cumulativeGasUsedHasBeenSet = true;
249 m_cumulativeGasUsed = std::forward<CumulativeGasUsedT>(value);
250 }
251 template <typename CumulativeGasUsedT = Aws::String>
252 Transaction& WithCumulativeGasUsed(CumulativeGasUsedT&& value) {
253 SetCumulativeGasUsed(std::forward<CumulativeGasUsedT>(value));
254 return *this;
255 }
257
259
262 inline const Aws::String& GetEffectiveGasPrice() const { return m_effectiveGasPrice; }
263 inline bool EffectiveGasPriceHasBeenSet() const { return m_effectiveGasPriceHasBeenSet; }
264 template <typename EffectiveGasPriceT = Aws::String>
265 void SetEffectiveGasPrice(EffectiveGasPriceT&& value) {
266 m_effectiveGasPriceHasBeenSet = true;
267 m_effectiveGasPrice = std::forward<EffectiveGasPriceT>(value);
268 }
269 template <typename EffectiveGasPriceT = Aws::String>
270 Transaction& WithEffectiveGasPrice(EffectiveGasPriceT&& value) {
271 SetEffectiveGasPrice(std::forward<EffectiveGasPriceT>(value));
272 return *this;
273 }
275
277
280 inline int GetSignatureV() const { return m_signatureV; }
281 inline bool SignatureVHasBeenSet() const { return m_signatureVHasBeenSet; }
282 inline void SetSignatureV(int value) {
283 m_signatureVHasBeenSet = true;
284 m_signatureV = value;
285 }
286 inline Transaction& WithSignatureV(int value) {
287 SetSignatureV(value);
288 return *this;
289 }
291
293
296 inline const Aws::String& GetSignatureR() const { return m_signatureR; }
297 inline bool SignatureRHasBeenSet() const { return m_signatureRHasBeenSet; }
298 template <typename SignatureRT = Aws::String>
299 void SetSignatureR(SignatureRT&& value) {
300 m_signatureRHasBeenSet = true;
301 m_signatureR = std::forward<SignatureRT>(value);
302 }
303 template <typename SignatureRT = Aws::String>
304 Transaction& WithSignatureR(SignatureRT&& value) {
305 SetSignatureR(std::forward<SignatureRT>(value));
306 return *this;
307 }
309
311
314 inline const Aws::String& GetSignatureS() const { return m_signatureS; }
315 inline bool SignatureSHasBeenSet() const { return m_signatureSHasBeenSet; }
316 template <typename SignatureST = Aws::String>
317 void SetSignatureS(SignatureST&& value) {
318 m_signatureSHasBeenSet = true;
319 m_signatureS = std::forward<SignatureST>(value);
320 }
321 template <typename SignatureST = Aws::String>
322 Transaction& WithSignatureS(SignatureST&& value) {
323 SetSignatureS(std::forward<SignatureST>(value));
324 return *this;
325 }
327
329
332 inline const Aws::String& GetTransactionFee() const { return m_transactionFee; }
333 inline bool TransactionFeeHasBeenSet() const { return m_transactionFeeHasBeenSet; }
334 template <typename TransactionFeeT = Aws::String>
335 void SetTransactionFee(TransactionFeeT&& value) {
336 m_transactionFeeHasBeenSet = true;
337 m_transactionFee = std::forward<TransactionFeeT>(value);
338 }
339 template <typename TransactionFeeT = Aws::String>
340 Transaction& WithTransactionFee(TransactionFeeT&& value) {
341 SetTransactionFee(std::forward<TransactionFeeT>(value));
342 return *this;
343 }
345
347
351 inline const Aws::String& GetTransactionId() const { return m_transactionId; }
352 inline bool TransactionIdHasBeenSet() const { return m_transactionIdHasBeenSet; }
353 template <typename TransactionIdT = Aws::String>
354 void SetTransactionId(TransactionIdT&& value) {
355 m_transactionIdHasBeenSet = true;
356 m_transactionId = std::forward<TransactionIdT>(value);
357 }
358 template <typename TransactionIdT = Aws::String>
359 Transaction& WithTransactionId(TransactionIdT&& value) {
360 SetTransactionId(std::forward<TransactionIdT>(value));
361 return *this;
362 }
364
366
369 inline ConfirmationStatus GetConfirmationStatus() const { return m_confirmationStatus; }
370 inline bool ConfirmationStatusHasBeenSet() const { return m_confirmationStatusHasBeenSet; }
372 m_confirmationStatusHasBeenSet = true;
373 m_confirmationStatus = value;
374 }
377 return *this;
378 }
380
382
385 inline ExecutionStatus GetExecutionStatus() const { return m_executionStatus; }
386 inline bool ExecutionStatusHasBeenSet() const { return m_executionStatusHasBeenSet; }
388 m_executionStatusHasBeenSet = true;
389 m_executionStatus = value;
390 }
392 SetExecutionStatus(value);
393 return *this;
394 }
396 private:
398
399 Aws::String m_blockHash;
400
401 Aws::String m_transactionHash;
402
403 Aws::String m_blockNumber;
404
405 Aws::Utils::DateTime m_transactionTimestamp{};
406
407 long long m_transactionIndex{0};
408
409 long long m_numberOfTransactions{0};
410
411 Aws::String m_to;
412
413 Aws::String m_from;
414
415 Aws::String m_contractAddress;
416
417 Aws::String m_gasUsed;
418
419 Aws::String m_cumulativeGasUsed;
420
421 Aws::String m_effectiveGasPrice;
422
423 int m_signatureV{0};
424
425 Aws::String m_signatureR;
426
427 Aws::String m_signatureS;
428
429 Aws::String m_transactionFee;
430
431 Aws::String m_transactionId;
432
434
435 ExecutionStatus m_executionStatus{ExecutionStatus::NOT_SET};
436 bool m_networkHasBeenSet = false;
437 bool m_blockHashHasBeenSet = false;
438 bool m_transactionHashHasBeenSet = false;
439 bool m_blockNumberHasBeenSet = false;
440 bool m_transactionTimestampHasBeenSet = false;
441 bool m_transactionIndexHasBeenSet = false;
442 bool m_numberOfTransactionsHasBeenSet = false;
443 bool m_toHasBeenSet = false;
444 bool m_fromHasBeenSet = false;
445 bool m_contractAddressHasBeenSet = false;
446 bool m_gasUsedHasBeenSet = false;
447 bool m_cumulativeGasUsedHasBeenSet = false;
448 bool m_effectiveGasPriceHasBeenSet = false;
449 bool m_signatureVHasBeenSet = false;
450 bool m_signatureRHasBeenSet = false;
451 bool m_signatureSHasBeenSet = false;
452 bool m_transactionFeeHasBeenSet = false;
453 bool m_transactionIdHasBeenSet = false;
454 bool m_confirmationStatusHasBeenSet = false;
455 bool m_executionStatusHasBeenSet = false;
456};
457
458} // namespace Model
459} // namespace ManagedBlockchainQuery
460} // namespace Aws
Transaction & WithCumulativeGasUsed(CumulativeGasUsedT &&value)
const Aws::String & GetTransactionFee() const
Transaction & WithSignatureS(SignatureST &&value)
void SetTransactionHash(TransactionHashT &&value)
Definition Transaction.h:87
Transaction & WithSignatureR(SignatureRT &&value)
Transaction & WithTransactionTimestamp(TransactionTimestampT &&value)
Transaction & WithNumberOfTransactions(long long value)
Transaction & WithContractAddress(ContractAddressT &&value)
Transaction & WithExecutionStatus(ExecutionStatus value)
void SetExecutionStatus(ExecutionStatus value)
void SetEffectiveGasPrice(EffectiveGasPriceT &&value)
void SetTransactionTimestamp(TransactionTimestampT &&value)
Transaction & WithTransactionIndex(long long value)
AWS_MANAGEDBLOCKCHAINQUERY_API Transaction(Aws::Utils::Json::JsonView jsonValue)
Transaction & WithTransactionFee(TransactionFeeT &&value)
Transaction & WithGasUsed(GasUsedT &&value)
void SetTransactionFee(TransactionFeeT &&value)
void SetContractAddress(ContractAddressT &&value)
Transaction & WithConfirmationStatus(ConfirmationStatus value)
void SetTransactionId(TransactionIdT &&value)
const Aws::Utils::DateTime & GetTransactionTimestamp() const
ConfirmationStatus GetConfirmationStatus() const
Transaction & WithBlockHash(BlockHashT &&value)
Definition Transaction.h:74
Transaction & WithTransactionId(TransactionIdT &&value)
Transaction & WithTransactionHash(TransactionHashT &&value)
Definition Transaction.h:92
void SetCumulativeGasUsed(CumulativeGasUsedT &&value)
Transaction & WithBlockNumber(BlockNumberT &&value)
const Aws::String & GetEffectiveGasPrice() const
Transaction & WithNetwork(QueryNetwork value)
Definition Transaction.h:54
const Aws::String & GetTransactionId() const
Transaction & WithEffectiveGasPrice(EffectiveGasPriceT &&value)
const Aws::String & GetTransactionHash() const
Definition Transaction.h:84
const Aws::String & GetContractAddress() const
AWS_MANAGEDBLOCKCHAINQUERY_API Aws::Utils::Json::JsonValue Jsonize() const
void SetConfirmationStatus(ConfirmationStatus value)
AWS_MANAGEDBLOCKCHAINQUERY_API Transaction & operator=(Aws::Utils::Json::JsonView jsonValue)
AWS_MANAGEDBLOCKCHAINQUERY_API Transaction()=default
const Aws::String & GetCumulativeGasUsed() const
std::basic_string< char, std::char_traits< char >, Aws::Allocator< char > > String
Aws::Utils::Json::JsonValue JsonValue