Class: Aws::BedrockAgentRuntime::EventStreams::FlowResponseStream

Inherits:
Object
  • Object
show all
Defined in:
gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb

Instance Method Summary collapse

Constructor Details

#initializeFlowResponseStream

Returns a new instance of FlowResponseStream.



108
109
110
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 108

def initialize
  @event_emitter = Aws::EventEmitter.new
end

Instance Method Details

#on_access_denied_exception_event(&block) ⇒ Object



112
113
114
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 112

def on_access_denied_exception_event(&block)
  @event_emitter.on(:access_denied_exception, block) if block_given?
end

#on_bad_gateway_exception_event(&block) ⇒ Object



116
117
118
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 116

def on_bad_gateway_exception_event(&block)
  @event_emitter.on(:bad_gateway_exception, block) if block_given?
end

#on_conflict_exception_event(&block) ⇒ Object



120
121
122
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 120

def on_conflict_exception_event(&block)
  @event_emitter.on(:conflict_exception, block) if block_given?
end

#on_dependency_failed_exception_event(&block) ⇒ Object



124
125
126
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 124

def on_dependency_failed_exception_event(&block)
  @event_emitter.on(:dependency_failed_exception, block) if block_given?
end

#on_error_event(&block) ⇒ Object



160
161
162
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 160

def on_error_event(&block)
  @event_emitter.on(:error, block) if block_given?
end

#on_event(&block) ⇒ Object



172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 172

def on_event(&block)
  on_access_denied_exception_event(&block)
  on_bad_gateway_exception_event(&block)
  on_conflict_exception_event(&block)
  on_dependency_failed_exception_event(&block)
  on_flow_completion_event_event(&block)
  on_flow_output_event_event(&block)
  on_flow_trace_event_event(&block)
  on_internal_server_exception_event(&block)
  on_resource_not_found_exception_event(&block)
  on_service_quota_exceeded_exception_event(&block)
  on_throttling_exception_event(&block)
  on_validation_exception_event(&block)
  on_error_event(&block)
  on_initial_response_event(&block)
  on_unknown_event(&block)
end

#on_flow_completion_event_event(&block) ⇒ Object



128
129
130
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 128

def on_flow_completion_event_event(&block)
  @event_emitter.on(:flow_completion_event, block) if block_given?
end

#on_flow_output_event_event(&block) ⇒ Object



132
133
134
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 132

def on_flow_output_event_event(&block)
  @event_emitter.on(:flow_output_event, block) if block_given?
end

#on_flow_trace_event_event(&block) ⇒ Object



136
137
138
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 136

def on_flow_trace_event_event(&block)
  @event_emitter.on(:flow_trace_event, block) if block_given?
end

#on_initial_response_event(&block) ⇒ Object



164
165
166
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 164

def on_initial_response_event(&block)
  @event_emitter.on(:initial_response, block) if block_given?
end

#on_internal_server_exception_event(&block) ⇒ Object



140
141
142
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 140

def on_internal_server_exception_event(&block)
  @event_emitter.on(:internal_server_exception, block) if block_given?
end

#on_resource_not_found_exception_event(&block) ⇒ Object



144
145
146
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 144

def on_resource_not_found_exception_event(&block)
  @event_emitter.on(:resource_not_found_exception, block) if block_given?
end

#on_service_quota_exceeded_exception_event(&block) ⇒ Object



148
149
150
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 148

def on_service_quota_exceeded_exception_event(&block)
  @event_emitter.on(:service_quota_exceeded_exception, block) if block_given?
end

#on_throttling_exception_event(&block) ⇒ Object



152
153
154
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 152

def on_throttling_exception_event(&block)
  @event_emitter.on(:throttling_exception, block) if block_given?
end

#on_unknown_event(&block) ⇒ Object



168
169
170
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 168

def on_unknown_event(&block)
  @event_emitter.on(:unknown_event, block) if block_given?
end

#on_validation_exception_event(&block) ⇒ Object



156
157
158
# File 'gems/aws-sdk-bedrockagentruntime/lib/aws-sdk-bedrockagentruntime/event_streams.rb', line 156

def on_validation_exception_event(&block)
  @event_emitter.on(:validation_exception, block) if block_given?
end