Class: Nfe::Generated::ContribuintesV2::DFeTech_TaxPayers_Domain_Entities_CityExtended

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

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeDFeTech_TaxPayers_Domain_Entities_CityExtended

Returns a new instance of DFeTech_TaxPayers_Domain_Entities_CityExtended.

Parameters:

  • code: (String, nil)
  • country: (String, nil)
  • name: (String, nil)
  • state: (String, nil)


14
# File 'sig/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rbs', line 14

def initialize: (?code: String?, ?country: String?, ?name: String?, ?state: String?) -> void

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code

Returns:

  • (Object)

    the current value of code



9
10
11
# File 'lib/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rb', line 9

def code
  @code
end

#countryObject (readonly)

Returns the value of attribute country

Returns:

  • (Object)

    the current value of country



9
10
11
# File 'lib/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rb', line 9

def country
  @country
end

#nameObject (readonly)

Returns the value of attribute name

Returns:

  • (Object)

    the current value of name



9
10
11
# File 'lib/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rb', line 9

def name
  @name
end

#stateObject (readonly)

Returns the value of attribute state

Returns:

  • (Object)

    the current value of state



9
10
11
# File 'lib/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rb', line 9

def state
  @state
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
# File 'lib/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rb', line 10

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

  new(
    code: payload["code"],
    country: payload["country"],
    name: payload["name"],
    state: payload["state"],
  )
end

.newinstance

Parameters:

  • code: (String, nil)
  • country: (String, nil)
  • name: (String, nil)
  • state: (String, nil)

Returns:

  • (instance)


13
# File 'sig/nfe/generated/contribuintes_v2/dfe_tech_tax_payers_domain_entities_city_extended.rbs', line 13

def self.new: (?code: String?, ?country: String?, ?name: String?, ?state: String?) -> instance