Class: Pin::Models::Charge

Inherits:
Object
  • Object
show all
Defined in:
lib/pin/models/charge.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(params) ⇒ Charge

Returns a new instance of Charge.



4
5
6
# File 'lib/pin/models/charge.rb', line 4

def initialize(params)
  params.each { |k, v| instance_variable_set("@#{k}", v) unless v.nil? }
end

Instance Attribute Details

#amountObject

Returns the value of attribute amount.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def amount
  @amount
end

#cardObject

Returns the value of attribute card.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def card
  @card
end

#created_atObject

Returns the value of attribute created_at.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def created_at
  @created_at
end

#currencyObject

Returns the value of attribute currency.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def currency
  @currency
end

#descriptionObject

Returns the value of attribute description.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def description
  @description
end

#emailObject

Returns the value of attribute email.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def email
  @email
end

#error_messageObject

Returns the value of attribute error_message.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def error_message
  @error_message
end

#ip_addressObject

Returns the value of attribute ip_address.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def ip_address
  @ip_address
end

#merchant_entitlementObject

Returns the value of attribute merchant_entitlement.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def merchant_entitlement
  @merchant_entitlement
end

#status_messageObject

Returns the value of attribute status_message.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def status_message
  @status_message
end

#successObject

Returns the value of attribute success.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def success
  @success
end

#tokenObject

Returns the value of attribute token.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def token
  @token
end

#total_feesObject

Returns the value of attribute total_fees.



2
3
4
# File 'lib/pin/models/charge.rb', line 2

def total_fees
  @total_fees
end