module BetfairApiNgRails::Api::Http::Helpers::InformationResponse

Public Class Methods

included(base) click to toggle source
# File lib/betfair_api_ng_rails/api/http/helpers/information_response.rb, line 6
          def self.included(base)
            base.send :class_eval,  <<-CODE
              def has_error_with_info_response?
                has_error_without_info_response? || info_response_error?
              end
              alias_method :has_error_without_info_response?, :has_error?
              alias_method :has_error?, :has_error_with_info_response?
            CODE
          end

Public Instance Methods

api_result() click to toggle source
# File lib/betfair_api_ng_rails/api/http/helpers/information_response.rb, line 16
def api_result
  result['result']
end

Protected Instance Methods

check_info_response_status() click to toggle source
# File lib/betfair_api_ng_rails/api/http/helpers/information_response.rb, line 26
def check_info_response_status
  result.has_key?('error')
end
info_response_error?() click to toggle source
# File lib/betfair_api_ng_rails/api/http/helpers/information_response.rb, line 22
def info_response_error?
  set_error_info(:API, result['error']) if check_info_response_status
end