AWS SDK for C++

AWS SDK for C++ Version 1.11.610

Loading...
Searching...
No Matches
InvokeModelWithBidirectionalStreamOutput.h
1
6#pragma once
7#include <aws/bedrock-runtime/BedrockRuntime_EXPORTS.h>
8#include <aws/bedrock-runtime/model/BidirectionalOutputPayloadPart.h>
9#include <aws/bedrock-runtime/model/ModelStreamErrorException.h>
10#include <utility>
11
12namespace Aws
13{
14namespace Utils
15{
16namespace Json
17{
18 class JsonValue;
19 class JsonView;
20} // namespace Json
21} // namespace Utils
22namespace BedrockRuntime
23{
24namespace Model
25{
26
34 {
35 public:
36 AWS_BEDROCKRUNTIME_API InvokeModelWithBidirectionalStreamOutput() = default;
39 AWS_BEDROCKRUNTIME_API Aws::Utils::Json::JsonValue Jsonize() const;
40
41
43
46 inline const BidirectionalOutputPayloadPart& GetChunk() const { return m_chunk; }
47 inline bool ChunkHasBeenSet() const { return m_chunkHasBeenSet; }
48 template<typename ChunkT = BidirectionalOutputPayloadPart>
49 void SetChunk(ChunkT&& value) { m_chunkHasBeenSet = true; m_chunk = std::forward<ChunkT>(value); }
50 template<typename ChunkT = BidirectionalOutputPayloadPart>
51 InvokeModelWithBidirectionalStreamOutput& WithChunk(ChunkT&& value) { SetChunk(std::forward<ChunkT>(value)); return *this;}
53
55
58 inline const BedrockRuntimeError& GetInternalServerException() const { return m_internalServerException; }
59 inline bool InternalServerExceptionHasBeenSet() const { return m_internalServerExceptionHasBeenSet; }
60 template<typename InternalServerExceptionT = BedrockRuntimeError>
61 void SetInternalServerException(InternalServerExceptionT&& value) { m_internalServerExceptionHasBeenSet = true; m_internalServerException = std::forward<InternalServerExceptionT>(value); }
62 template<typename InternalServerExceptionT = BedrockRuntimeError>
63 InvokeModelWithBidirectionalStreamOutput& WithInternalServerException(InternalServerExceptionT&& value) { SetInternalServerException(std::forward<InternalServerExceptionT>(value)); return *this;}
65
67
70 inline const ModelStreamErrorException& GetModelStreamErrorException() const { return m_modelStreamErrorException; }
71 inline bool ModelStreamErrorExceptionHasBeenSet() const { return m_modelStreamErrorExceptionHasBeenSet; }
72 template<typename ModelStreamErrorExceptionT = ModelStreamErrorException>
73 void SetModelStreamErrorException(ModelStreamErrorExceptionT&& value) { m_modelStreamErrorExceptionHasBeenSet = true; m_modelStreamErrorException = std::forward<ModelStreamErrorExceptionT>(value); }
74 template<typename ModelStreamErrorExceptionT = ModelStreamErrorException>
75 InvokeModelWithBidirectionalStreamOutput& WithModelStreamErrorException(ModelStreamErrorExceptionT&& value) { SetModelStreamErrorException(std::forward<ModelStreamErrorExceptionT>(value)); return *this;}
77
79
83 inline const BedrockRuntimeError& GetValidationException() const { return m_validationException; }
84 inline bool ValidationExceptionHasBeenSet() const { return m_validationExceptionHasBeenSet; }
85 template<typename ValidationExceptionT = BedrockRuntimeError>
86 void SetValidationException(ValidationExceptionT&& value) { m_validationExceptionHasBeenSet = true; m_validationException = std::forward<ValidationExceptionT>(value); }
87 template<typename ValidationExceptionT = BedrockRuntimeError>
88 InvokeModelWithBidirectionalStreamOutput& WithValidationException(ValidationExceptionT&& value) { SetValidationException(std::forward<ValidationExceptionT>(value)); return *this;}
90
92
95 inline const BedrockRuntimeError& GetThrottlingException() const { return m_throttlingException; }
96 inline bool ThrottlingExceptionHasBeenSet() const { return m_throttlingExceptionHasBeenSet; }
97 template<typename ThrottlingExceptionT = BedrockRuntimeError>
98 void SetThrottlingException(ThrottlingExceptionT&& value) { m_throttlingExceptionHasBeenSet = true; m_throttlingException = std::forward<ThrottlingExceptionT>(value); }
99 template<typename ThrottlingExceptionT = BedrockRuntimeError>
100 InvokeModelWithBidirectionalStreamOutput& WithThrottlingException(ThrottlingExceptionT&& value) { SetThrottlingException(std::forward<ThrottlingExceptionT>(value)); return *this;}
102
104
108 inline const BedrockRuntimeError& GetModelTimeoutException() const { return m_modelTimeoutException; }
109 inline bool ModelTimeoutExceptionHasBeenSet() const { return m_modelTimeoutExceptionHasBeenSet; }
110 template<typename ModelTimeoutExceptionT = BedrockRuntimeError>
111 void SetModelTimeoutException(ModelTimeoutExceptionT&& value) { m_modelTimeoutExceptionHasBeenSet = true; m_modelTimeoutException = std::forward<ModelTimeoutExceptionT>(value); }
112 template<typename ModelTimeoutExceptionT = BedrockRuntimeError>
113 InvokeModelWithBidirectionalStreamOutput& WithModelTimeoutException(ModelTimeoutExceptionT&& value) { SetModelTimeoutException(std::forward<ModelTimeoutExceptionT>(value)); return *this;}
115
117
120 inline const BedrockRuntimeError& GetServiceUnavailableException() const { return m_serviceUnavailableException; }
121 inline bool ServiceUnavailableExceptionHasBeenSet() const { return m_serviceUnavailableExceptionHasBeenSet; }
122 template<typename ServiceUnavailableExceptionT = BedrockRuntimeError>
123 void SetServiceUnavailableException(ServiceUnavailableExceptionT&& value) { m_serviceUnavailableExceptionHasBeenSet = true; m_serviceUnavailableException = std::forward<ServiceUnavailableExceptionT>(value); }
124 template<typename ServiceUnavailableExceptionT = BedrockRuntimeError>
125 InvokeModelWithBidirectionalStreamOutput& WithServiceUnavailableException(ServiceUnavailableExceptionT&& value) { SetServiceUnavailableException(std::forward<ServiceUnavailableExceptionT>(value)); return *this;}
127 private:
128
130 bool m_chunkHasBeenSet = false;
131
132 BedrockRuntimeError m_internalServerException;
133 bool m_internalServerExceptionHasBeenSet = false;
134
135 ModelStreamErrorException m_modelStreamErrorException;
136 bool m_modelStreamErrorExceptionHasBeenSet = false;
137
138 BedrockRuntimeError m_validationException;
139 bool m_validationExceptionHasBeenSet = false;
140
141 BedrockRuntimeError m_throttlingException;
142 bool m_throttlingExceptionHasBeenSet = false;
143
144 BedrockRuntimeError m_modelTimeoutException;
145 bool m_modelTimeoutExceptionHasBeenSet = false;
146
147 BedrockRuntimeError m_serviceUnavailableException;
148 bool m_serviceUnavailableExceptionHasBeenSet = false;
149 };
150
151} // namespace Model
152} // namespace BedrockRuntime
153} // namespace Aws
InvokeModelWithBidirectionalStreamOutput & WithThrottlingException(ThrottlingExceptionT &&value)
InvokeModelWithBidirectionalStreamOutput & WithInternalServerException(InternalServerExceptionT &&value)
InvokeModelWithBidirectionalStreamOutput & WithServiceUnavailableException(ServiceUnavailableExceptionT &&value)
AWS_BEDROCKRUNTIME_API Aws::Utils::Json::JsonValue Jsonize() const
InvokeModelWithBidirectionalStreamOutput & WithModelTimeoutException(ModelTimeoutExceptionT &&value)
InvokeModelWithBidirectionalStreamOutput & WithModelStreamErrorException(ModelStreamErrorExceptionT &&value)
InvokeModelWithBidirectionalStreamOutput & WithValidationException(ValidationExceptionT &&value)
AWS_BEDROCKRUNTIME_API InvokeModelWithBidirectionalStreamOutput(Aws::Utils::Json::JsonView jsonValue)
AWS_BEDROCKRUNTIME_API InvokeModelWithBidirectionalStreamOutput & operator=(Aws::Utils::Json::JsonView jsonValue)
Aws::Utils::Json::JsonValue JsonValue