Class: Eancom::Edifact::UNZ

Inherits:
Segment
  • Object
show all
Defined in:
lib/eancom/edifact/segments/unz.rb

Constant Summary collapse

TAG =
'UNZ'.freeze
TYPE =
:footer.freeze

Instance Attribute Summary

Attributes inherited from Segment

#tag

Instance Method Summary collapse

Methods inherited from Segment

#array, #group_name, initialize_by_components, #is_body?, #is_footer?, #is_header?, #item_group_name, #starts_item?, #starts_location?, #starts_message?, #structure, #tag?, #to_edi, #to_hash, #to_s, #validate_structure

Constructor Details

#initialize(tag: nil, interchange_control_count:, interchange_control_reference:) ⇒ UNZ

Returns a new instance of UNZ.



7
8
9
10
11
12
13
14
15
16
# File 'lib/eancom/edifact/segments/unz.rb', line 7

def initialize(
  tag: nil,
  interchange_control_count:,
  interchange_control_reference:
)
  @tag = tag
  @interchange_control_count = interchange_control_count
  @interchange_control_reference = interchange_control_reference
  super(tag: tag || TAG)
end

Instance Method Details

#segment_typeObject



22
23
24
# File 'lib/eancom/edifact/segments/unz.rb', line 22

def segment_type
  TYPE
end

#to_json_hashObject



18
19
20
# File 'lib/eancom/edifact/segments/unz.rb', line 18

def to_json_hash
  {}
end