Class: AllAirlinesResults

Inherits:
Object
  • Object
show all
Defined in:
lib/FlightXML2REST.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(allAirlinesResult = nil) ⇒ AllAirlinesResults

Returns a new instance of AllAirlinesResults.



417
418
419
420
421
422
423
424
425
426
427
428
# File 'lib/FlightXML2REST.rb', line 417

def initialize(allAirlinesResult = nil)
  begin
    rawAllAirlinesResult = JSON.parse(allAirlinesResult)
    allAirlinesResult = rawAllAirlinesResult['AllAirlinesResult']
    @allAirlinesResult = ArrayOfString.new()
    allAirlinesResult['data'].each do |data|
      @allAirlinesResult.data << data
    end
  rescue
      raise FlightAwareError.new(rawAllAirlinesResult['error']).error
  end
end

Instance Attribute Details

#allAirlinesResultObject

Returns the value of attribute allAirlinesResult.



416
417
418
# File 'lib/FlightXML2REST.rb', line 416

def allAirlinesResult
  @allAirlinesResult
end