Class: Nfe::Generated::NfProdutoV2::ExportResource

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

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initializeExportResource

Returns a new instance of ExportResource.

Parameters:

  • local: (String, nil)
  • office: (String, nil)
  • state: (Object)


13
# File 'sig/nfe/generated/nf_produto_v2/export_resource.rbs', line 13

def initialize: (?local: String?, ?office: String?, ?state: untyped) -> void

Instance Attribute Details

#localObject (readonly)

Returns the value of attribute local

Returns:

  • (Object)

    the current value of local



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

def local
  @local
end

#officeObject (readonly)

Returns the value of attribute office

Returns:

  • (Object)

    the current value of office



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

def office
  @office
end

#stateObject (readonly)

Returns the value of attribute state

Returns:

  • (Object)

    the current value of state



9
10
11
# File 'lib/nfe/generated/nf_produto_v2/export_resource.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
# File 'lib/nfe/generated/nf_produto_v2/export_resource.rb', line 10

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

  new(
    local: payload["local"],
    office: payload["office"],
    state: payload["state"],
  )
end

.newinstance

Parameters:

  • local: (String, nil)
  • office: (String, nil)
  • state: (Object)

Returns:

  • (instance)


12
# File 'sig/nfe/generated/nf_produto_v2/export_resource.rbs', line 12

def self.new: (?local: String?, ?office: String?, ?state: untyped) -> instance