class Response::Resp

Public Class Methods

new(paramlist) click to toggle source
# File lib/kount/Response.rb, line 6
def initialize(paramlist)
  @paramlist = paramlist
  puts @paramlist
end

Public Instance Methods

get_auto() click to toggle source
# File lib/kount/Response.rb, line 46
def get_auto
  auto = @paramlist['AUTO'].to_s
  return auto unless auto.empty?
end
get_brand() click to toggle source
# File lib/kount/Response.rb, line 66
def get_brand
  brand = @paramlist['BRND'].to_s
  return brand unless brand.empty?
end
get_browser() click to toggle source
# File lib/kount/Response.rb, line 291
def get_browser
  browser = @paramlist['BROWSER'].to_s
  return browser unless browser.empty?
end
get_cards() click to toggle source
# File lib/kount/Response.rb, line 116
def get_cards
  cards = @paramlist['CARDS'].to_s
  return cards unless cards.empty?
end
get_cookies() click to toggle source
# File lib/kount/Response.rb, line 181
def get_cookies
  cookie = @paramlist['COOKIES'].to_s
  return cookie unless cookie.empty?
end
get_counters_triggered() click to toggle source
# File lib/kount/Response.rb, line 345
def get_counters_triggered
  counters = []
  numCounters = get_numbercounters_triggered
  (0..numCounters.to_i - 1).each do |i|
    countername = @paramlist["COUNTER_NAME_#{i}"]
    counters[countername.to_s] = @paramlist["COUNTER_VALUE_#{i}"]
  end
  counters.compact
end
get_country() click to toggle source
# File lib/kount/Response.rb, line 171
def get_country
  country = @paramlist['COUNTRY'].to_s
  return country unless country.empty?
end
get_date_device_firstseen() click to toggle source
# File lib/kount/Response.rb, line 271
def get_date_device_firstseen
  ddfs = @paramlist['DDFS'].to_s
  return ddfs unless ddfs.empty?
end
get_device_layers() click to toggle source
# File lib/kount/Response.rb, line 131
def get_device_layers
  device_layers = @paramlist['DEVICE_LAYERS'].to_s
  return device_layers unless device_layers.empty?
end
get_devices() click to toggle source
# File lib/kount/Response.rb, line 126
def get_devices
  devices = @paramlist['DEVICES'].to_s
  return devices unless devices.empty?
end
get_devicescreen_resolution() click to toggle source
# File lib/kount/Response.rb, line 281
def get_devicescreen_resolution
  dsr = @paramlist['DSR'].to_s
  return dsr unless dsr.empty?
end
get_emails() click to toggle source
# File lib/kount/Response.rb, line 101
def get_emails
  email = @paramlist['EMAILS'].to_s
  return email unless email.empty?
end
get_error_count() click to toggle source
# File lib/kount/Response.rb, line 325
def get_error_count
  # changed due to rubocop styling rules for ruby
  @paramlist['ERROR_COUNT'].to_s
end
get_errors() click to toggle source
# File lib/kount/Response.rb, line 330
def get_errors
  errors = []
  error_count = get_error_count.to_i
  (0..error_count - 1).each do |i|
    errors << @paramlist["ERROR_#{i}"]
  end
  errors.compact
end
Also aliased as: geterrors
get_fingerprint() click to toggle source
# File lib/kount/Response.rb, line 156
def get_fingerprint
  fingerprint = @paramlist['FINGERPRINT'].to_s
  return fingerprint unless fingerprint.empty?
end
get_flash() click to toggle source
# File lib/kount/Response.rb, line 161
def get_flash
  flash = @paramlist['FLASH'].to_s
  return flash unless flash.empty?
end
get_geox() click to toggle source
# File lib/kount/Response.rb, line 61
def get_geox
  geox = @paramlist['GEOX'].to_s
  return geox unless geox.empty?
end
get_http_country() click to toggle source
# File lib/kount/Response.rb, line 106
def get_http_country
  httmcountry = @paramlist['HTTP_COUNTRY'].to_s
  return httmcountry unless httmcountry.empty?
end
get_ipaddress() click to toggle source
# File lib/kount/Response.rb, line 226
def get_ipaddress
  ip_ipad = @paramlist['IP_IPAD'].to_s
  return ip_ipad unless ip_ipad.empty?
end
get_ipaddress_city() click to toggle source
# File lib/kount/Response.rb, line 261
def get_ipaddress_city
  ip_city = @paramlist['IP_CITY'].to_s
  return ip_city unless ip_city.empty?
end
get_ipaddress_country() click to toggle source
# File lib/kount/Response.rb, line 251
def get_ipaddress_country
  ip_country = @paramlist['IP_COUNTRY'].to_s
  return ip_country unless ip_country.empty?
end
get_ipaddress_latitude() click to toggle source
# File lib/kount/Response.rb, line 231
def get_ipaddress_latitude
  ip_lat = @paramlist['IP_LAT'].to_s
  return ip_lat unless ip_lat.empty?
end
get_ipaddress_longitude() click to toggle source
# File lib/kount/Response.rb, line 246
def get_ipaddress_longitude
  ip_long = @paramlist['IP_LON'].to_s
  return ip_long unless ip_long.empty?
end
get_ipaddress_organization() click to toggle source
# File lib/kount/Response.rb, line 266
def get_ipaddress_organization
  ip_org = @paramlist['IP_ORG'].to_s
  return ip_org unless ip_org.empty?
end
get_ipaddress_region() click to toggle source
# File lib/kount/Response.rb, line 256
def get_ipaddress_region
  ip_region = @paramlist['IP_REGION'].to_s
  return ip_region unless ip_region.empty?
end
get_javascript() click to toggle source
# File lib/kount/Response.rb, line 176
def get_javascript
  javascript = @paramlist['JAVASCRIPT'].to_s
  return javascript unless javascript.empty?
end
get_kaptcha() click to toggle source
# File lib/kount/Response.rb, line 91
def get_kaptcha
  kapt = @paramlist['KAPT'].to_s
  return kapt unless kapt.empty?
end
get_language() click to toggle source
# File lib/kount/Response.rb, line 166
def get_language
  language = @paramlist['LANGUAGE'].to_s
  return language unless language.empty?
end
get_local_time() click to toggle source
# File lib/kount/Response.rb, line 146
def get_local_time
  localtime = @paramlist['LOCALTIME'].to_s
  return localtime unless localtime.empty?
end
get_merchant_id() click to toggle source
# File lib/kount/Response.rb, line 26
def get_merchant_id
  merchantid = @paramlist['MERC'].to_s
  return merchantid unless merchantid.empty?
end
get_mobile_device() click to toggle source
# File lib/kount/Response.rb, line 186
def get_mobile_device
  mobiledevice = @paramlist['MOBILE_DEVICE'].to_s
  return mobiledevice unless mobiledevice.empty?
end
get_mobile_forwarder() click to toggle source
# File lib/kount/Response.rb, line 136
def get_mobile_forwarder
  mobile_forwarder = @paramlist['MOBILE_FORWARDER'].to_s
  return mobile_forwarder unless mobile_forwarder.empty?
end
get_mobile_type() click to toggle source
# File lib/kount/Response.rb, line 151
def get_mobile_type
  mobiletype = @paramlist['MOBILE_TYPE'].to_s
  return mobiletype unless mobiletype.empty?
end
get_mode() click to toggle source
# File lib/kount/Response.rb, line 11
def get_mode
  modes = @paramlist['MODE'].to_s
  return modes unless modes.empty?
end
get_network() click to toggle source
# File lib/kount/Response.rb, line 81
def get_network
  network = @paramlist['NETW'].to_s
  return network unless network.empty?
end
get_numbercounters_triggered() click to toggle source
# File lib/kount/Response.rb, line 340
def get_numbercounters_triggered
  # changed due to rubocop styling rules for ruby
  @paramlist['COUNTERS_TRIGGERED'].to_s
end
get_numberrules_triggered() click to toggle source
# File lib/kount/Response.rb, line 296
def get_numberrules_triggered
  # changed due to rubocop styling rules for ruby
  @paramlist['RULES_TRIGGERED'].to_s
end
get_omniscore() click to toggle source
# File lib/kount/Response.rb, line 56
def get_omniscore
  omniscore = @paramlist['OMNISCORE'].to_s
  return omniscore unless omniscore.empty?
end
get_order_number() click to toggle source
# File lib/kount/Response.rb, line 36
def get_order_number
  orderno = @paramlist['ORDR'].to_s
  return orderno unless orderno.empty?
end
get_os() click to toggle source
# File lib/kount/Response.rb, line 286
def get_os
  os = @paramlist['OS'].to_s
  return os unless os.empty?
end
get_pc_remote() click to toggle source
# File lib/kount/Response.rb, line 121
def get_pc_remote
  pcremote = @paramlist['PC_REMOTE'].to_s
  return pcremote unless pcremote.empty?
end
get_pierced_ipaddress() click to toggle source
# File lib/kount/Response.rb, line 191
def get_pierced_ipaddress
  pip_address = @paramlist['PIP_IPAD'].to_s
  return pip_address unless pip_address.empty?
end
get_piercedipaddress_city() click to toggle source
# File lib/kount/Response.rb, line 216
def get_piercedipaddress_city
  pip_city = @paramlist['PIP_CITY'].to_s
  return pip_city unless pip_city.empty?
end
get_piercedipaddress_country() click to toggle source
# File lib/kount/Response.rb, line 206
def get_piercedipaddress_country
  pip_country = @paramlist['PIP_COUNTRY'].to_s
  return pip_country unless pip_country.empty?
end
get_piercedipaddress_latitude() click to toggle source
# File lib/kount/Response.rb, line 196
def get_piercedipaddress_latitude
  pip_lat = @paramlist['PIP_LAT'].to_s
  return pip_lat unless pip_lat.empty?
end
get_piercedipaddress_longitude() click to toggle source
# File lib/kount/Response.rb, line 201
def get_piercedipaddress_longitude
  pip_long = @paramlist['PIP_LON'].to_s
  return pip_long unless pip_long.empty?
end
get_piercedipaddress_organization() click to toggle source
# File lib/kount/Response.rb, line 221
def get_piercedipaddress_organization
  pip_org = @paramlist['PIP_ORG'].to_s
  return pip_org unless pip_org.empty?
end
get_piercedipaddress_region() click to toggle source
# File lib/kount/Response.rb, line 211
def get_piercedipaddress_region
  pip_region = @paramlist['PIP_REGION'].to_s
  return pip_region unless pip_region.empty?
end
get_previous_whitelisted() click to toggle source
# File lib/kount/Response.rb, line 236
def get_previous_whitelisted
  whitelisted = @paramlist['PREVIOUSLY_WHITELISTED'].to_s
  return whitelisted unless whitelisted.empty?
end
get_proxy() click to toggle source
# File lib/kount/Response.rb, line 96
def get_proxy
  proxy = @paramlist['PROXY'].to_s
  return proxy unless proxy.empty?
end
get_region() click to toggle source
# File lib/kount/Response.rb, line 86
def get_region
  region = @paramlist['REGN'].to_s
  return region unless region.empty?
end
get_rules_triggered() click to toggle source
# File lib/kount/Response.rb, line 301
def get_rules_triggered
  rules_count = get_numberrules_triggered
  rules = []
  (0..rules_count.to_i - 1).each do |i|
    ruleid = @paramlist["RULE_ID_#{i}"]
    rules[ruleid.to_i] = @paramlist["RULE_DESCRIPTION_#{i}"]
  end
  rules.compact
end
get_score() click to toggle source
# File lib/kount/Response.rb, line 51
def get_score
  score = @paramlist['SCOR'].to_s
  return score unless score.empty?
end
get_secure_merchant_response() click to toggle source
# File lib/kount/Response.rb, line 241
def get_secure_merchant_response
  merchant_response = @paramlist['THREE_DS_MERCHANT_RESPONSE'].to_s
  return merchant_response unless merchant_response.empty?
end
get_session_id() click to toggle source
# File lib/kount/Response.rb, line 31
def get_session_id
  sessionid = @paramlist['SESS'].to_s
  return sessionid unless sessionid.empty?
end
get_site() click to toggle source
# File lib/kount/Response.rb, line 41
def get_site
  site = @paramlist['SITE'].to_s
  return site unless site.empty?
end
get_timezone() click to toggle source
# File lib/kount/Response.rb, line 111
def get_timezone
  timezone = @paramlist['TIMEZONE'].to_s
  return timezone unless timezone.empty?
end
get_transaction_id() click to toggle source
# File lib/kount/Response.rb, line 21
def get_transaction_id
  tran = @paramlist['TRAN'].to_s
  return tran unless tran.empty?
end
get_useragent_string() click to toggle source
# File lib/kount/Response.rb, line 276
def get_useragent_string
  user_agent = @paramlist['UAS'].to_s
  return user_agent unless user_agent.empty?
end
get_velo() click to toggle source
# File lib/kount/Response.rb, line 71
def get_velo
  velo = @paramlist['VELO'].to_s
  return velo unless velo.empty?
end
get_version() click to toggle source
# File lib/kount/Response.rb, line 16
def get_version
  vers = @paramlist['VERS'].to_s
  return vers unless vers.empty?
end
get_vmax() click to toggle source
# File lib/kount/Response.rb, line 76
def get_vmax
  vmax = @paramlist['VMAX'].to_s
  return vmax unless vmax.empty?
end
get_voice_device() click to toggle source
# File lib/kount/Response.rb, line 141
def get_voice_device
  voicedevice = @paramlist['VOICE_DEVICE'].to_s
  return voicedevice unless voicedevice.empty?
end
get_warning_count() click to toggle source
# File lib/kount/Response.rb, line 311
def get_warning_count
  # changed due to rubocop styling rules for ruby
  @paramlist['WARNING_COUNT'].to_s
end
get_warnings() click to toggle source
# File lib/kount/Response.rb, line 316
def get_warnings
  warnings = []
  warningcount = get_warning_count
  (0..warningcount.to_i - 1).each do |i|
    warnings = @paramlist["WARNING_#{i}"]
  end
  warnings.compact
end
geterrors()
Alias for: get_errors