Class: Radar::API::AnalyzerController::Processor

Inherits:
Object
  • Object
show all
Includes:
Thrift::Processor
Defined in:
lib/radar/api/analyzer_controller.rb

Instance Method Summary collapse

Instance Method Details

#process_analyzers(seqid, iprot, oprot) ⇒ Object



137
138
139
140
141
142
# File 'lib/radar/api/analyzer_controller.rb', line 137

def process_analyzers(seqid, iprot, oprot)
  args = read_args(iprot, Analyzers_args)
  result = Analyzers_result.new()
  result.success = @handler.analyzers()
  write_result(result, oprot, 'analyzers', seqid)
end

#process_create_session(seqid, iprot, oprot) ⇒ Object



168
169
170
171
172
173
# File 'lib/radar/api/analyzer_controller.rb', line 168

def process_create_session(seqid, iprot, oprot)
  args = read_args(iprot, Create_session_args)
  result = Create_session_result.new()
  result.success = @handler.create_session(args.session_id, args.analyzer_id)
  write_result(result, oprot, 'create_session', seqid)
end

#process_destroy_session(seqid, iprot, oprot) ⇒ Object



202
203
204
205
206
# File 'lib/radar/api/analyzer_controller.rb', line 202

def process_destroy_session(seqid, iprot, oprot)
  args = read_args(iprot, Destroy_session_args)
  @handler.destroy_session(args.session_id)
  return
end

#process_dump(seqid, iprot, oprot) ⇒ Object



175
176
177
178
179
180
# File 'lib/radar/api/analyzer_controller.rb', line 175

def process_dump(seqid, iprot, oprot)
  args = read_args(iprot, Dump_args)
  result = Dump_result.new()
  result.success = @handler.dump(args.session_id)
  write_result(result, oprot, 'dump', seqid)
end

#process_example_result(seqid, iprot, oprot) ⇒ Object



195
196
197
198
199
200
# File 'lib/radar/api/analyzer_controller.rb', line 195

def process_example_result(seqid, iprot, oprot)
  args = read_args(iprot, Example_result_args)
  result = Example_result_result.new()
  @handler.example_result(args.session_id)
  write_result(result, oprot, 'example_result', seqid)
end

#process_on_cash_flow(seqid, iprot, oprot) ⇒ Object



162
163
164
165
166
# File 'lib/radar/api/analyzer_controller.rb', line 162

def process_on_cash_flow(seqid, iprot, oprot)
  args = read_args(iprot, On_cash_flow_args)
  @handler.on_cash_flow(args.session_id, args.cash_flow)
  return
end

#process_on_each_day(seqid, iprot, oprot) ⇒ Object



144
145
146
147
148
# File 'lib/radar/api/analyzer_controller.rb', line 144

def process_on_each_day(seqid, iprot, oprot)
  args = read_args(iprot, On_each_day_args)
  @handler.on_each_day(args.sessionid, args.portfolio)
  return
end

#process_on_each_month(seqid, iprot, oprot) ⇒ Object



150
151
152
153
154
# File 'lib/radar/api/analyzer_controller.rb', line 150

def process_on_each_month(seqid, iprot, oprot)
  args = read_args(iprot, On_each_month_args)
  @handler.on_each_month(args.sessionid, args.portfolio)
  return
end

#process_on_finish(seqid, iprot, oprot) ⇒ Object



156
157
158
159
160
# File 'lib/radar/api/analyzer_controller.rb', line 156

def process_on_finish(seqid, iprot, oprot)
  args = read_args(iprot, On_finish_args)
  @handler.on_finish(args.session_id, args.portfolio)
  return
end

#process_result(seqid, iprot, oprot) ⇒ Object



188
189
190
191
192
193
# File 'lib/radar/api/analyzer_controller.rb', line 188

def process_result(seqid, iprot, oprot)
  args = read_args(iprot, Result_args)
  result = Result_result.new()
  result.success = @handler.result(args.session_id)
  write_result(result, oprot, 'result', seqid)
end

#process_resume(seqid, iprot, oprot) ⇒ Object



182
183
184
185
186
# File 'lib/radar/api/analyzer_controller.rb', line 182

def process_resume(seqid, iprot, oprot)
  args = read_args(iprot, Resume_args)
  @handler.resume(args.session_id, args.data)
  return
end