Class: Nfe::Generated::NfConsumidorV2::TotalResource
- Inherits:
-
Data
- Object
- Data
- Nfe::Generated::NfConsumidorV2::TotalResource
- Defined in:
- lib/nfe/generated/nf_consumidor_v2/total_resource.rb,
sig/nfe/generated/nf_consumidor_v2/total_resource.rbs
Instance Attribute Summary collapse
-
#ibs_cbs_totals ⇒ Object
readonly
Returns the value of attribute ibs_cbs_totals.
-
#icms ⇒ Object
readonly
Returns the value of attribute icms.
-
#is_totals ⇒ Object
readonly
Returns the value of attribute is_totals.
-
#issqn ⇒ Object
readonly
Returns the value of attribute issqn.
-
#total_invoice_amount ⇒ Object
readonly
Returns the value of attribute total_invoice_amount.
-
#withheld_taxes ⇒ Object
readonly
Returns the value of attribute withheld_taxes.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ TotalResource
constructor
A new instance of TotalResource.
Constructor Details
#initialize ⇒ TotalResource
Returns a new instance of TotalResource.
16 |
# File 'sig/nfe/generated/nf_consumidor_v2/total_resource.rbs', line 16
def initialize: (?ibs_cbs_totals: IBSCBSTotalsResource, ?icms: ICMSTotalResource, ?is_totals: ISTotalsResource, ?issqn: ISSQNTotalResource, ?total_invoice_amount: Float?, ?withheld_taxes: TotalsWithholdings) -> void
|
Instance Attribute Details
#ibs_cbs_totals ⇒ Object (readonly)
Returns the value of attribute ibs_cbs_totals
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def ibs_cbs_totals @ibs_cbs_totals end |
#icms ⇒ Object (readonly)
Returns the value of attribute icms
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def icms @icms end |
#is_totals ⇒ Object (readonly)
Returns the value of attribute is_totals
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def is_totals @is_totals end |
#issqn ⇒ Object (readonly)
Returns the value of attribute issqn
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def issqn @issqn end |
#total_invoice_amount ⇒ Object (readonly)
Returns the value of attribute total_invoice_amount
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def total_invoice_amount @total_invoice_amount end |
#withheld_taxes ⇒ Object (readonly)
Returns the value of attribute withheld_taxes
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 9 def withheld_taxes @withheld_taxes end |
Class Method Details
.from_api(payload) ⇒ instance?
10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'lib/nfe/generated/nf_consumidor_v2/total_resource.rb', line 10 def self.from_api(payload) return nil if payload.nil? new( ibs_cbs_totals: IBSCBSTotalsResource.from_api(payload["ibsCbsTotals"]), icms: ICMSTotalResource.from_api(payload["icms"]), is_totals: ISTotalsResource.from_api(payload["isTotals"]), issqn: ISSQNTotalResource.from_api(payload["issqn"]), total_invoice_amount: payload["totalInvoiceAmount"], withheld_taxes: TotalsWithholdings.from_api(payload["withheldTaxes"]), ) end |
.new ⇒ instance
15 |
# File 'sig/nfe/generated/nf_consumidor_v2/total_resource.rbs', line 15
def self.new: (?ibs_cbs_totals: IBSCBSTotalsResource, ?icms: ICMSTotalResource, ?is_totals: ISTotalsResource, ?issqn: ISSQNTotalResource, ?total_invoice_amount: Float?, ?withheld_taxes: TotalsWithholdings) -> instance
|