Class: Nfe::Generated::NfProdutoV2::IcmsTaxResource

Inherits:
Data
  • Object
show all
Defined in:
lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb,
sig/nfe/generated/nf_produto_v2/icms_tax_resource.rbs

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeIcmsTaxResource

Returns a new instance of IcmsTaxResource.

Parameters:

  • amount: (Float, nil)
  • amount_operation: (String, nil)
  • amount_streason: (String, nil)
  • base_deferred: (String, nil)
  • base_snretention_amount: (String, nil)
  • base_stretention_amount: (String, nil)
  • base_tax: (Float, nil)
  • base_tax_fcpstamount: (Float, nil)
  • base_tax_modality: (String, nil)
  • base_tax_operation_percentual: (String, nil)
  • base_tax_reduction: (Float, nil)
  • base_tax_st: (Float, nil)
  • base_tax_stmodality: (String, nil)
  • base_tax_streduction: (String, nil)
  • csosn: (String, nil)
  • cst: (String, nil)
  • deduction_indicator: (Object)
  • effective_amount: (Float, nil)
  • effective_base_tax_amount: (Float, nil)
  • effective_base_tax_reduction_rate: (Float, nil)
  • effective_rate: (Float, nil)
  • exempt_amount: (Float, nil)
  • exempt_amount_st: (Float, nil)
  • exempt_reason: (Object)
  • exempt_reason_st: (Object)
  • fcp_amount: (Float, nil)
  • fcp_rate: (Float, nil)
  • fcpst_amount: (Float, nil)
  • fcpst_rate: (Float, nil)
  • fcpst_ret_amount: (Float, nil)
  • fcpst_ret_rate: (Float, nil)
  • origin: (String)
  • percentual: (Float, nil)
  • percentual_deferment: (String, nil)
  • rate: (Float, nil)
  • sn_credit_amount: (Float, nil)
  • sn_credit_rate: (Float, nil)
  • sn_retention_amount: (String, nil)
  • st_amount: (Float, nil)
  • st_final_consumer_rate: (Float, nil)
  • st_margin_added_amount: (String, nil)
  • st_margin_amount: (Float, nil)
  • st_rate: (Float, nil)
  • st_retention_amount: (String, nil)
  • substitute_amount: (Float, nil)
  • ufst: (String, nil)


56
# File 'sig/nfe/generated/nf_produto_v2/icms_tax_resource.rbs', line 56

def initialize: (?amount: Float?, ?amount_operation: String?, ?amount_streason: String?, ?base_deferred: String?, ?base_snretention_amount: String?, ?base_stretention_amount: String?, ?base_tax: Float?, ?base_tax_fcpstamount: Float?, ?base_tax_modality: String?, ?base_tax_operation_percentual: String?, ?base_tax_reduction: Float?, ?base_tax_st: Float?, ?base_tax_stmodality: String?, ?base_tax_streduction: String?, ?csosn: String?, ?cst: String?, ?deduction_indicator: untyped, ?effective_amount: Float?, ?effective_base_tax_amount: Float?, ?effective_base_tax_reduction_rate: Float?, ?effective_rate: Float?, ?exempt_amount: Float?, ?exempt_amount_st: Float?, ?exempt_reason: untyped, ?exempt_reason_st: untyped, ?fcp_amount: Float?, ?fcp_rate: Float?, ?fcpst_amount: Float?, ?fcpst_rate: Float?, ?fcpst_ret_amount: Float?, ?fcpst_ret_rate: Float?, origin: String, ?percentual: Float?, ?percentual_deferment: String?, ?rate: Float?, ?sn_credit_amount: Float?, ?sn_credit_rate: Float?, ?sn_retention_amount: String?, ?st_amount: Float?, ?st_final_consumer_rate: Float?, ?st_margin_added_amount: String?, ?st_margin_amount: Float?, ?st_rate: Float?, ?st_retention_amount: String?, ?substitute_amount: Float?, ?ufst: String?) -> void

Instance Attribute Details

#amountObject (readonly)

Returns the value of attribute amount

Returns:

  • (Object)

    the current value of amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def amount
  @amount
end

#amount_operationObject (readonly)

Returns the value of attribute amount_operation

Returns:

  • (Object)

    the current value of amount_operation



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def amount_operation
  @amount_operation
end

#amount_streasonObject (readonly)

Returns the value of attribute amount_streason

Returns:

  • (Object)

    the current value of amount_streason



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def amount_streason
  @amount_streason
end

#base_deferredObject (readonly)

Returns the value of attribute base_deferred

Returns:

  • (Object)

    the current value of base_deferred



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_deferred
  @base_deferred
end

#base_snretention_amountObject (readonly)

Returns the value of attribute base_snretention_amount

Returns:

  • (Object)

    the current value of base_snretention_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_snretention_amount
  @base_snretention_amount
end

#base_stretention_amountObject (readonly)

Returns the value of attribute base_stretention_amount

Returns:

  • (Object)

    the current value of base_stretention_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_stretention_amount
  @base_stretention_amount
end

#base_taxObject (readonly)

Returns the value of attribute base_tax

Returns:

  • (Object)

    the current value of base_tax



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax
  @base_tax
end

#base_tax_fcpstamountObject (readonly)

Returns the value of attribute base_tax_fcpstamount

Returns:

  • (Object)

    the current value of base_tax_fcpstamount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_fcpstamount
  @base_tax_fcpstamount
end

#base_tax_modalityObject (readonly)

Returns the value of attribute base_tax_modality

Returns:

  • (Object)

    the current value of base_tax_modality



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_modality
  @base_tax_modality
end

#base_tax_operation_percentualObject (readonly)

Returns the value of attribute base_tax_operation_percentual

Returns:

  • (Object)

    the current value of base_tax_operation_percentual



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_operation_percentual
  @base_tax_operation_percentual
end

#base_tax_reductionObject (readonly)

Returns the value of attribute base_tax_reduction

Returns:

  • (Object)

    the current value of base_tax_reduction



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_reduction
  @base_tax_reduction
end

#base_tax_stObject (readonly)

Returns the value of attribute base_tax_st

Returns:

  • (Object)

    the current value of base_tax_st



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_st
  @base_tax_st
end

#base_tax_stmodalityObject (readonly)

Returns the value of attribute base_tax_stmodality

Returns:

  • (Object)

    the current value of base_tax_stmodality



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_stmodality
  @base_tax_stmodality
end

#base_tax_streductionObject (readonly)

Returns the value of attribute base_tax_streduction

Returns:

  • (Object)

    the current value of base_tax_streduction



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def base_tax_streduction
  @base_tax_streduction
end

#csosnObject (readonly)

Returns the value of attribute csosn

Returns:

  • (Object)

    the current value of csosn



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def csosn
  @csosn
end

#cstObject (readonly)

Returns the value of attribute cst

Returns:

  • (Object)

    the current value of cst



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def cst
  @cst
end

#deduction_indicatorObject (readonly)

Returns the value of attribute deduction_indicator

Returns:

  • (Object)

    the current value of deduction_indicator



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def deduction_indicator
  @deduction_indicator
end

#effective_amountObject (readonly)

Returns the value of attribute effective_amount

Returns:

  • (Object)

    the current value of effective_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def effective_amount
  @effective_amount
end

#effective_base_tax_amountObject (readonly)

Returns the value of attribute effective_base_tax_amount

Returns:

  • (Object)

    the current value of effective_base_tax_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def effective_base_tax_amount
  @effective_base_tax_amount
end

#effective_base_tax_reduction_rateObject (readonly)

Returns the value of attribute effective_base_tax_reduction_rate

Returns:

  • (Object)

    the current value of effective_base_tax_reduction_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def effective_base_tax_reduction_rate
  @effective_base_tax_reduction_rate
end

#effective_rateObject (readonly)

Returns the value of attribute effective_rate

Returns:

  • (Object)

    the current value of effective_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def effective_rate
  @effective_rate
end

#exempt_amountObject (readonly)

Returns the value of attribute exempt_amount

Returns:

  • (Object)

    the current value of exempt_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def exempt_amount
  @exempt_amount
end

#exempt_amount_stObject (readonly)

Returns the value of attribute exempt_amount_st

Returns:

  • (Object)

    the current value of exempt_amount_st



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def exempt_amount_st
  @exempt_amount_st
end

#exempt_reasonObject (readonly)

Returns the value of attribute exempt_reason

Returns:

  • (Object)

    the current value of exempt_reason



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def exempt_reason
  @exempt_reason
end

#exempt_reason_stObject (readonly)

Returns the value of attribute exempt_reason_st

Returns:

  • (Object)

    the current value of exempt_reason_st



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def exempt_reason_st
  @exempt_reason_st
end

#fcp_amountObject (readonly)

Returns the value of attribute fcp_amount

Returns:

  • (Object)

    the current value of fcp_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcp_amount
  @fcp_amount
end

#fcp_rateObject (readonly)

Returns the value of attribute fcp_rate

Returns:

  • (Object)

    the current value of fcp_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcp_rate
  @fcp_rate
end

#fcpst_amountObject (readonly)

Returns the value of attribute fcpst_amount

Returns:

  • (Object)

    the current value of fcpst_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcpst_amount
  @fcpst_amount
end

#fcpst_rateObject (readonly)

Returns the value of attribute fcpst_rate

Returns:

  • (Object)

    the current value of fcpst_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcpst_rate
  @fcpst_rate
end

#fcpst_ret_amountObject (readonly)

Returns the value of attribute fcpst_ret_amount

Returns:

  • (Object)

    the current value of fcpst_ret_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcpst_ret_amount
  @fcpst_ret_amount
end

#fcpst_ret_rateObject (readonly)

Returns the value of attribute fcpst_ret_rate

Returns:

  • (Object)

    the current value of fcpst_ret_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def fcpst_ret_rate
  @fcpst_ret_rate
end

#originObject (readonly)

Returns the value of attribute origin

Returns:

  • (Object)

    the current value of origin



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def origin
  @origin
end

#percentualObject (readonly)

Returns the value of attribute percentual

Returns:

  • (Object)

    the current value of percentual



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def percentual
  @percentual
end

#percentual_defermentObject (readonly)

Returns the value of attribute percentual_deferment

Returns:

  • (Object)

    the current value of percentual_deferment



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def percentual_deferment
  @percentual_deferment
end

#rateObject (readonly)

Returns the value of attribute rate

Returns:

  • (Object)

    the current value of rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def rate
  @rate
end

#sn_credit_amountObject (readonly)

Returns the value of attribute sn_credit_amount

Returns:

  • (Object)

    the current value of sn_credit_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def sn_credit_amount
  @sn_credit_amount
end

#sn_credit_rateObject (readonly)

Returns the value of attribute sn_credit_rate

Returns:

  • (Object)

    the current value of sn_credit_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def sn_credit_rate
  @sn_credit_rate
end

#sn_retention_amountObject (readonly)

Returns the value of attribute sn_retention_amount

Returns:

  • (Object)

    the current value of sn_retention_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def sn_retention_amount
  @sn_retention_amount
end

#st_amountObject (readonly)

Returns the value of attribute st_amount

Returns:

  • (Object)

    the current value of st_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_amount
  @st_amount
end

#st_final_consumer_rateObject (readonly)

Returns the value of attribute st_final_consumer_rate

Returns:

  • (Object)

    the current value of st_final_consumer_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_final_consumer_rate
  @st_final_consumer_rate
end

#st_margin_added_amountObject (readonly)

Returns the value of attribute st_margin_added_amount

Returns:

  • (Object)

    the current value of st_margin_added_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_margin_added_amount
  @st_margin_added_amount
end

#st_margin_amountObject (readonly)

Returns the value of attribute st_margin_amount

Returns:

  • (Object)

    the current value of st_margin_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_margin_amount
  @st_margin_amount
end

#st_rateObject (readonly)

Returns the value of attribute st_rate

Returns:

  • (Object)

    the current value of st_rate



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_rate
  @st_rate
end

#st_retention_amountObject (readonly)

Returns the value of attribute st_retention_amount

Returns:

  • (Object)

    the current value of st_retention_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def st_retention_amount
  @st_retention_amount
end

#substitute_amountObject (readonly)

Returns the value of attribute substitute_amount

Returns:

  • (Object)

    the current value of substitute_amount



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def substitute_amount
  @substitute_amount
end

#ufstObject (readonly)

Returns the value of attribute ufst

Returns:

  • (Object)

    the current value of ufst



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 9

def ufst
  @ufst
end

Class Method Details

.from_api(payload) ⇒ instance?

Parameters:

  • payload (Hash[String, untyped], nil)

Returns:

  • (instance, nil)


10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# File 'lib/nfe/generated/nf_produto_v2/icms_tax_resource.rb', line 10

def self.from_api(payload)
  return nil if payload.nil?

  new(
    amount: payload["amount"],
    amount_operation: payload["amountOperation"],
    amount_streason: payload["amountSTReason"],
    base_deferred: payload["baseDeferred"],
    base_snretention_amount: payload["baseSNRetentionAmount"],
    base_stretention_amount: payload["baseSTRetentionAmount"],
    base_tax: payload["baseTax"],
    base_tax_fcpstamount: payload["baseTaxFCPSTAmount"],
    base_tax_modality: payload["baseTaxModality"],
    base_tax_operation_percentual: payload["baseTaxOperationPercentual"],
    base_tax_reduction: payload["baseTaxReduction"],
    base_tax_st: payload["baseTaxST"],
    base_tax_stmodality: payload["baseTaxSTModality"],
    base_tax_streduction: payload["baseTaxSTReduction"],
    csosn: payload["csosn"],
    cst: payload["cst"],
    deduction_indicator: payload["deductionIndicator"],
    effective_amount: payload["effectiveAmount"],
    effective_base_tax_amount: payload["effectiveBaseTaxAmount"],
    effective_base_tax_reduction_rate: payload["effectiveBaseTaxReductionRate"],
    effective_rate: payload["effectiveRate"],
    exempt_amount: payload["exemptAmount"],
    exempt_amount_st: payload["exemptAmountST"],
    exempt_reason: payload["exemptReason"],
    exempt_reason_st: payload["exemptReasonST"],
    fcp_amount: payload["fcpAmount"],
    fcp_rate: payload["fcpRate"],
    fcpst_amount: payload["fcpstAmount"],
    fcpst_rate: payload["fcpstRate"],
    fcpst_ret_amount: payload["fcpstRetAmount"],
    fcpst_ret_rate: payload["fcpstRetRate"],
    origin: payload["origin"],
    percentual: payload["percentual"],
    percentual_deferment: payload["percentualDeferment"],
    rate: payload["rate"],
    sn_credit_amount: payload["snCreditAmount"],
    sn_credit_rate: payload["snCreditRate"],
    sn_retention_amount: payload["snRetentionAmount"],
    st_amount: payload["stAmount"],
    st_final_consumer_rate: payload["stFinalConsumerRate"],
    st_margin_added_amount: payload["stMarginAddedAmount"],
    st_margin_amount: payload["stMarginAmount"],
    st_rate: payload["stRate"],
    st_retention_amount: payload["stRetentionAmount"],
    substitute_amount: payload["substituteAmount"],
    ufst: payload["ufst"],
  )
end

.newinstance

Parameters:

  • amount: (Float, nil)
  • amount_operation: (String, nil)
  • amount_streason: (String, nil)
  • base_deferred: (String, nil)
  • base_snretention_amount: (String, nil)
  • base_stretention_amount: (String, nil)
  • base_tax: (Float, nil)
  • base_tax_fcpstamount: (Float, nil)
  • base_tax_modality: (String, nil)
  • base_tax_operation_percentual: (String, nil)
  • base_tax_reduction: (Float, nil)
  • base_tax_st: (Float, nil)
  • base_tax_stmodality: (String, nil)
  • base_tax_streduction: (String, nil)
  • csosn: (String, nil)
  • cst: (String, nil)
  • deduction_indicator: (Object)
  • effective_amount: (Float, nil)
  • effective_base_tax_amount: (Float, nil)
  • effective_base_tax_reduction_rate: (Float, nil)
  • effective_rate: (Float, nil)
  • exempt_amount: (Float, nil)
  • exempt_amount_st: (Float, nil)
  • exempt_reason: (Object)
  • exempt_reason_st: (Object)
  • fcp_amount: (Float, nil)
  • fcp_rate: (Float, nil)
  • fcpst_amount: (Float, nil)
  • fcpst_rate: (Float, nil)
  • fcpst_ret_amount: (Float, nil)
  • fcpst_ret_rate: (Float, nil)
  • origin: (String)
  • percentual: (Float, nil)
  • percentual_deferment: (String, nil)
  • rate: (Float, nil)
  • sn_credit_amount: (Float, nil)
  • sn_credit_rate: (Float, nil)
  • sn_retention_amount: (String, nil)
  • st_amount: (Float, nil)
  • st_final_consumer_rate: (Float, nil)
  • st_margin_added_amount: (String, nil)
  • st_margin_amount: (Float, nil)
  • st_rate: (Float, nil)
  • st_retention_amount: (String, nil)
  • substitute_amount: (Float, nil)
  • ufst: (String, nil)

Returns:

  • (instance)


55
# File 'sig/nfe/generated/nf_produto_v2/icms_tax_resource.rbs', line 55

def self.new: (?amount: Float?, ?amount_operation: String?, ?amount_streason: String?, ?base_deferred: String?, ?base_snretention_amount: String?, ?base_stretention_amount: String?, ?base_tax: Float?, ?base_tax_fcpstamount: Float?, ?base_tax_modality: String?, ?base_tax_operation_percentual: String?, ?base_tax_reduction: Float?, ?base_tax_st: Float?, ?base_tax_stmodality: String?, ?base_tax_streduction: String?, ?csosn: String?, ?cst: String?, ?deduction_indicator: untyped, ?effective_amount: Float?, ?effective_base_tax_amount: Float?, ?effective_base_tax_reduction_rate: Float?, ?effective_rate: Float?, ?exempt_amount: Float?, ?exempt_amount_st: Float?, ?exempt_reason: untyped, ?exempt_reason_st: untyped, ?fcp_amount: Float?, ?fcp_rate: Float?, ?fcpst_amount: Float?, ?fcpst_rate: Float?, ?fcpst_ret_amount: Float?, ?fcpst_ret_rate: Float?, origin: String, ?percentual: Float?, ?percentual_deferment: String?, ?rate: Float?, ?sn_credit_amount: Float?, ?sn_credit_rate: Float?, ?sn_retention_amount: String?, ?st_amount: Float?, ?st_final_consumer_rate: Float?, ?st_margin_added_amount: String?, ?st_margin_amount: Float?, ?st_rate: Float?, ?st_retention_amount: String?, ?substitute_amount: Float?, ?ufst: String?) -> instance