Class: Paymongo::Entities::BillingEntity
- Inherits:
-
BaseEntity
- Object
- BaseEntity
- Paymongo::Entities::BillingEntity
- Defined in:
- lib/paymongo/entities/billing_entity.rb
Instance Attribute Summary collapse
-
#address_city ⇒ Object
readonly
Returns the value of attribute address_city.
-
#address_country ⇒ Object
readonly
Returns the value of attribute address_country.
-
#address_line1 ⇒ Object
readonly
Returns the value of attribute address_line1.
-
#address_line2 ⇒ Object
readonly
Returns the value of attribute address_line2.
-
#address_postal_code ⇒ Object
readonly
Returns the value of attribute address_postal_code.
-
#address_state ⇒ Object
readonly
Returns the value of attribute address_state.
-
#email ⇒ Object
readonly
Returns the value of attribute email.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#phone ⇒ Object
readonly
Returns the value of attribute phone.
Instance Method Summary collapse
-
#initialize(data) ⇒ BillingEntity
constructor
A new instance of BillingEntity.
Constructor Details
#initialize(data) ⇒ BillingEntity
Returns a new instance of BillingEntity.
15 16 17 18 19 20 21 22 23 24 25 |
# File 'lib/paymongo/entities/billing_entity.rb', line 15 def initialize(data) @address_city = data['address']['city'] @address_country = data['address']['country'] @address_line1 = data['address']['line1'] @address_line2 = data['address']['line2'] @address_postal_code = data['address']['postal_code'] @address_state = data['address']['state'] @email = data['email'] @name = data['name'] @phone = data['phone'] end |
Instance Attribute Details
#address_city ⇒ Object (readonly)
Returns the value of attribute address_city.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_city @address_city end |
#address_country ⇒ Object (readonly)
Returns the value of attribute address_country.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_country @address_country end |
#address_line1 ⇒ Object (readonly)
Returns the value of attribute address_line1.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_line1 @address_line1 end |
#address_line2 ⇒ Object (readonly)
Returns the value of attribute address_line2.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_line2 @address_line2 end |
#address_postal_code ⇒ Object (readonly)
Returns the value of attribute address_postal_code.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_postal_code @address_postal_code end |
#address_state ⇒ Object (readonly)
Returns the value of attribute address_state.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def address_state @address_state end |
#email ⇒ Object (readonly)
Returns the value of attribute email.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def email @email end |
#id ⇒ Object (readonly)
Returns the value of attribute id.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def id @id end |
#name ⇒ Object (readonly)
Returns the value of attribute name.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def name @name end |
#phone ⇒ Object (readonly)
Returns the value of attribute phone.
4 5 6 |
# File 'lib/paymongo/entities/billing_entity.rb', line 4 def phone @phone end |