Class: Nfe::Generated::NfProdutoV2::IPITaxResource
- Inherits:
-
Data
- Object
- Data
- Nfe::Generated::NfProdutoV2::IPITaxResource
- Defined in:
- lib/nfe/generated/nf_produto_v2/ipitax_resource.rb,
sig/nfe/generated/nf_produto_v2/ipitax_resource.rbs
Instance Attribute Summary collapse
-
#amount ⇒ Object
readonly
Returns the value of attribute amount.
-
#base ⇒ Object
readonly
Returns the value of attribute base.
-
#classification ⇒ Object
readonly
Returns the value of attribute classification.
-
#classification_code ⇒ Object
readonly
Returns the value of attribute classification_code.
-
#cst ⇒ Object
readonly
Returns the value of attribute cst.
-
#producer_cnpj ⇒ Object
readonly
Returns the value of attribute producer_cnpj.
-
#rate ⇒ Object
readonly
Returns the value of attribute rate.
-
#stamp_code ⇒ Object
readonly
Returns the value of attribute stamp_code.
-
#stamp_quantity ⇒ Object
readonly
Returns the value of attribute stamp_quantity.
-
#unit_amount ⇒ Object
readonly
Returns the value of attribute unit_amount.
-
#unit_quantity ⇒ Object
readonly
Returns the value of attribute unit_quantity.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ IPITaxResource
constructor
A new instance of IPITaxResource.
Constructor Details
#initialize ⇒ IPITaxResource
Returns a new instance of IPITaxResource.
21 |
# File 'sig/nfe/generated/nf_produto_v2/ipitax_resource.rbs', line 21
def initialize: (?amount: Float?, ?base: Float?, ?classification: String?, ?classification_code: String?, ?cst: String?, ?producer_cnpj: String?, ?rate: Float?, ?stamp_code: String?, ?stamp_quantity: Float?, ?unit_amount: Float?, ?unit_quantity: Float?) -> void
|
Instance Attribute Details
#amount ⇒ Object (readonly)
Returns the value of attribute amount
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def amount @amount end |
#base ⇒ Object (readonly)
Returns the value of attribute base
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def base @base end |
#classification ⇒ Object (readonly)
Returns the value of attribute classification
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def classification @classification end |
#classification_code ⇒ Object (readonly)
Returns the value of attribute classification_code
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def classification_code @classification_code end |
#cst ⇒ Object (readonly)
Returns the value of attribute cst
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def cst @cst end |
#producer_cnpj ⇒ Object (readonly)
Returns the value of attribute producer_cnpj
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def producer_cnpj @producer_cnpj end |
#rate ⇒ Object (readonly)
Returns the value of attribute rate
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def rate @rate end |
#stamp_code ⇒ Object (readonly)
Returns the value of attribute stamp_code
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def stamp_code @stamp_code end |
#stamp_quantity ⇒ Object (readonly)
Returns the value of attribute stamp_quantity
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def stamp_quantity @stamp_quantity end |
#unit_amount ⇒ Object (readonly)
Returns the value of attribute unit_amount
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def unit_amount @unit_amount end |
#unit_quantity ⇒ Object (readonly)
Returns the value of attribute unit_quantity
9 10 11 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 9 def unit_quantity @unit_quantity end |
Class Method Details
.from_api(payload) ⇒ instance?
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/nfe/generated/nf_produto_v2/ipitax_resource.rb', line 10 def self.from_api(payload) return nil if payload.nil? new( amount: payload["amount"], base: payload["base"], classification: payload["classification"], classification_code: payload["classificationCode"], cst: payload["cst"], producer_cnpj: payload["producerCNPJ"], rate: payload["rate"], stamp_code: payload["stampCode"], stamp_quantity: payload["stampQuantity"], unit_amount: payload["unitAmount"], unit_quantity: payload["unitQuantity"], ) end |
.new ⇒ instance
20 |
# File 'sig/nfe/generated/nf_produto_v2/ipitax_resource.rbs', line 20
def self.new: (?amount: Float?, ?base: Float?, ?classification: String?, ?classification_code: String?, ?cst: String?, ?producer_cnpj: String?, ?rate: Float?, ?stamp_code: String?, ?stamp_quantity: Float?, ?unit_amount: Float?, ?unit_quantity: Float?) -> instance
|