Class: Square::Connect::Tax

Inherits:
Object
  • Object
show all
Defined in:
lib/square/connect/tax.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(attributes = {}) ⇒ Tax

Returns a new instance of Tax.



6
7
8
9
10
11
12
13
# File 'lib/square/connect/tax.rb', line 6

def initialize(attributes = {})
  self.name = attributes[:name]
  self.applied_money = if attributes[:applied_money]
    Money.new attributes[:applied_money]
  end
  self.rate = attributes[:rate]
  self.inclusion_type = attributes[:inclusion_type]
end

Instance Attribute Details

#applied_moneyObject

Returns the value of attribute applied_money.



4
5
6
# File 'lib/square/connect/tax.rb', line 4

def applied_money
  @applied_money
end

#inclusion_typeObject

Returns the value of attribute inclusion_type.



4
5
6
# File 'lib/square/connect/tax.rb', line 4

def inclusion_type
  @inclusion_type
end

#nameObject

Returns the value of attribute name.



4
5
6
# File 'lib/square/connect/tax.rb', line 4

def name
  @name
end

#rateObject

Returns the value of attribute rate.



4
5
6
# File 'lib/square/connect/tax.rb', line 4

def rate
  @rate
end