Class: HQMF2::Reference

Inherits:
Object
  • Object
show all
Includes:
Utilities
Defined in:
lib/hqmf-parser/2.0/types.rb

Overview

Represents a HQMF reference from a precondition to a data criteria

Instance Method Summary collapse

Methods included from Utilities

#attr_val, attr_val, #to_xml

Methods included from HQMF::Conversion::Utilities

#build_hash, #check_equality, #json_array, #openstruct_to_json

Constructor Details

#initialize(entry) ⇒ Reference

Returns a new instance of Reference.



210
211
212
# File 'lib/hqmf-parser/2.0/types.rb', line 210

def initialize(entry)
  @entry = entry
end

Instance Method Details

#idObject



214
215
216
# File 'lib/hqmf-parser/2.0/types.rb', line 214

def id
  attr_val('./@extension')
end

#to_modelObject



218
219
220
# File 'lib/hqmf-parser/2.0/types.rb', line 218

def to_model
  HQMF::Reference.new(id)
end