Class: TowerdataEmail::Response

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

Overview

A wrapper to the response from an email search request

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response) ⇒ Response

Returns a new instance of Response.



93
94
95
96
97
# File 'lib/towerdata_email.rb', line 93

def initialize(response)
  @email = Email.new(response['email'])
  @postal = Postal.new(response['found_postal'])
  @demographics = Demographics.new(response['demographics'])
end

Instance Attribute Details

#demographicsObject

Returns the value of attribute demographics.



91
92
93
# File 'lib/towerdata_email.rb', line 91

def demographics
  @demographics
end

#emailObject

Returns the value of attribute email.



91
92
93
# File 'lib/towerdata_email.rb', line 91

def email
  @email
end

#postalObject

Returns the value of attribute postal.



91
92
93
# File 'lib/towerdata_email.rb', line 91

def postal
  @postal
end