Class: Nfe::Generated::NfConsumidorV2::IssuerResource
- Inherits:
-
Data
- Object
- Data
- Nfe::Generated::NfConsumidorV2::IssuerResource
- Defined in:
- lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb,
sig/nfe/generated/nf_consumidor_v2/issuer_resource.rbs
Instance Attribute Summary collapse
-
#account_id ⇒ Object
readonly
Returns the value of attribute account_id.
-
#address ⇒ Object
readonly
Returns the value of attribute address.
-
#company_registry_number ⇒ Object
readonly
Returns the value of attribute company_registry_number.
-
#economic_activities ⇒ Object
readonly
Returns the value of attribute economic_activities.
-
#email ⇒ Object
readonly
Returns the value of attribute email.
-
#federal_tax_number ⇒ Object
readonly
Returns the value of attribute federal_tax_number.
-
#id ⇒ Object
readonly
Returns the value of attribute id.
-
#legal_nature ⇒ Object
readonly
Returns the value of attribute legal_nature.
-
#municipal_tax_number ⇒ Object
readonly
Returns the value of attribute municipal_tax_number.
-
#name ⇒ Object
readonly
Returns the value of attribute name.
-
#openning_date ⇒ Object
readonly
Returns the value of attribute openning_date.
-
#regional_sttax_number ⇒ Object
readonly
Returns the value of attribute regional_sttax_number.
-
#regional_tax_number ⇒ Object
readonly
Returns the value of attribute regional_tax_number.
-
#special_tax_regime ⇒ Object
readonly
Returns the value of attribute special_tax_regime.
-
#st_state_tax_number ⇒ Object
readonly
Returns the value of attribute st_state_tax_number.
-
#tax_regime ⇒ Object
readonly
Returns the value of attribute tax_regime.
-
#trade_name ⇒ Object
readonly
Returns the value of attribute trade_name.
-
#type ⇒ Object
readonly
Returns the value of attribute type.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize ⇒ IssuerResource
constructor
A new instance of IssuerResource.
Constructor Details
#initialize ⇒ IssuerResource
Returns a new instance of IssuerResource.
28 |
# File 'sig/nfe/generated/nf_consumidor_v2/issuer_resource.rbs', line 28
def initialize: (?account_id: String?, ?address: AddressResource, ?company_registry_number: Integer?, ?economic_activities: Array[EconomicActivityResource]?, ?email: String?, ?federal_tax_number: Integer?, ?id: String?, ?legal_nature: untyped, ?municipal_tax_number: String?, ?name: String?, ?openning_date: String?, ?regional_sttax_number: Integer?, ?regional_tax_number: Integer?, ?special_tax_regime: untyped, ?st_state_tax_number: String?, ?tax_regime: untyped, ?trade_name: String?, ?type: untyped) -> void
|
Instance Attribute Details
#account_id ⇒ Object (readonly)
Returns the value of attribute account_id
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def account_id @account_id end |
#address ⇒ Object (readonly)
Returns the value of attribute address
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def address @address end |
#company_registry_number ⇒ Object (readonly)
Returns the value of attribute company_registry_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def company_registry_number @company_registry_number end |
#economic_activities ⇒ Object (readonly)
Returns the value of attribute economic_activities
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def economic_activities @economic_activities end |
#email ⇒ Object (readonly)
Returns the value of attribute email
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def email @email end |
#federal_tax_number ⇒ Object (readonly)
Returns the value of attribute federal_tax_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def federal_tax_number @federal_tax_number end |
#id ⇒ Object (readonly)
Returns the value of attribute id
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def id @id end |
#legal_nature ⇒ Object (readonly)
Returns the value of attribute legal_nature
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def legal_nature @legal_nature end |
#municipal_tax_number ⇒ Object (readonly)
Returns the value of attribute municipal_tax_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def municipal_tax_number @municipal_tax_number end |
#name ⇒ Object (readonly)
Returns the value of attribute name
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def name @name end |
#openning_date ⇒ Object (readonly)
Returns the value of attribute openning_date
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def openning_date @openning_date end |
#regional_sttax_number ⇒ Object (readonly)
Returns the value of attribute regional_sttax_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def regional_sttax_number @regional_sttax_number end |
#regional_tax_number ⇒ Object (readonly)
Returns the value of attribute regional_tax_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def regional_tax_number @regional_tax_number end |
#special_tax_regime ⇒ Object (readonly)
Returns the value of attribute special_tax_regime
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def special_tax_regime @special_tax_regime end |
#st_state_tax_number ⇒ Object (readonly)
Returns the value of attribute st_state_tax_number
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def st_state_tax_number @st_state_tax_number end |
#tax_regime ⇒ Object (readonly)
Returns the value of attribute tax_regime
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def tax_regime @tax_regime end |
#trade_name ⇒ Object (readonly)
Returns the value of attribute trade_name
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def trade_name @trade_name end |
#type ⇒ Object (readonly)
Returns the value of attribute type
9 10 11 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 9 def type @type 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 27 28 29 30 31 32 33 |
# File 'lib/nfe/generated/nf_consumidor_v2/issuer_resource.rb', line 10 def self.from_api(payload) return nil if payload.nil? new( account_id: payload["accountId"], address: AddressResource.from_api(payload["address"]), company_registry_number: payload["companyRegistryNumber"], economic_activities: (payload["economicActivities"] || []).map { |e| EconomicActivityResource.from_api(e) }, email: payload["email"], federal_tax_number: payload["federalTaxNumber"], id: payload["id"], legal_nature: payload["legalNature"], municipal_tax_number: payload["municipalTaxNumber"], name: payload["name"], openning_date: payload["openningDate"], regional_sttax_number: payload["regionalSTTaxNumber"], regional_tax_number: payload["regionalTaxNumber"], special_tax_regime: payload["specialTaxRegime"], st_state_tax_number: payload["stStateTaxNumber"], tax_regime: payload["taxRegime"], trade_name: payload["tradeName"], type: payload["type"], ) end |
.new ⇒ instance
27 |
# File 'sig/nfe/generated/nf_consumidor_v2/issuer_resource.rbs', line 27
def self.new: (?account_id: String?, ?address: AddressResource, ?company_registry_number: Integer?, ?economic_activities: Array[EconomicActivityResource]?, ?email: String?, ?federal_tax_number: Integer?, ?id: String?, ?legal_nature: untyped, ?municipal_tax_number: String?, ?name: String?, ?openning_date: String?, ?regional_sttax_number: Integer?, ?regional_tax_number: Integer?, ?special_tax_regime: untyped, ?st_state_tax_number: String?, ?tax_regime: untyped, ?trade_name: String?, ?type: untyped) -> instance
|