Class: Synapsis::RetrievedUser
- Inherits:
-
Object
- Object
- Synapsis::RetrievedUser
- Defined in:
- lib/synapsis/user.rb
Instance Attribute Summary collapse
-
#accept_bank_payments ⇒ Object
Returns the value of attribute accept_bank_payments.
-
#accept_gratuity ⇒ Object
Returns the value of attribute accept_gratuity.
-
#balance ⇒ Object
Returns the value of attribute balance.
-
#email ⇒ Object
Returns the value of attribute email.
-
#fullname ⇒ Object
Returns the value of attribute fullname.
-
#has_avatar ⇒ Object
Returns the value of attribute has_avatar.
-
#phone_number ⇒ Object
Returns the value of attribute phone_number.
-
#resource_uri ⇒ Object
Returns the value of attribute resource_uri.
-
#seller_details ⇒ Object
Returns the value of attribute seller_details.
-
#user_id ⇒ Object
Returns the value of attribute user_id.
-
#username ⇒ Object
Returns the value of attribute username.
-
#visit_count ⇒ Object
Returns the value of attribute visit_count.
-
#visit_message ⇒ Object
Returns the value of attribute visit_message.
Instance Method Summary collapse
-
#initialize(synapse_response) ⇒ RetrievedUser
constructor
A new instance of RetrievedUser.
Constructor Details
#initialize(synapse_response) ⇒ RetrievedUser
Returns a new instance of RetrievedUser.
80 81 82 83 84 85 86 |
# File 'lib/synapsis/user.rb', line 80 def initialize(synapse_response) parsed_response = JSON.parse(synapse_response.body) parsed_response['user'].each do |k, v| send("#{k}=", v) end end |
Instance Attribute Details
#accept_bank_payments ⇒ Object
Returns the value of attribute accept_bank_payments.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def accept_bank_payments @accept_bank_payments end |
#accept_gratuity ⇒ Object
Returns the value of attribute accept_gratuity.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def accept_gratuity @accept_gratuity end |
#balance ⇒ Object
Returns the value of attribute balance.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def balance @balance end |
#email ⇒ Object
Returns the value of attribute email.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def email @email end |
#fullname ⇒ Object
Returns the value of attribute fullname.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def fullname @fullname end |
#has_avatar ⇒ Object
Returns the value of attribute has_avatar.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def has_avatar @has_avatar end |
#phone_number ⇒ Object
Returns the value of attribute phone_number.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def phone_number @phone_number end |
#resource_uri ⇒ Object
Returns the value of attribute resource_uri.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def resource_uri @resource_uri end |
#seller_details ⇒ Object
Returns the value of attribute seller_details.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def seller_details @seller_details end |
#user_id ⇒ Object
Returns the value of attribute user_id.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def user_id @user_id end |
#username ⇒ Object
Returns the value of attribute username.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def username @username end |
#visit_count ⇒ Object
Returns the value of attribute visit_count.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def visit_count @visit_count end |
#visit_message ⇒ Object
Returns the value of attribute visit_message.
66 67 68 |
# File 'lib/synapsis/user.rb', line 66 def @visit_message end |