class Metanorma::Plugin::Lutaml::LutamlDiagramBlock

Public Instance Methods

lutaml_file(document, reader) click to toggle source
# File lib/metanorma/plugin/lutaml/lutaml_diagram_block.rb, line 16
def lutaml_file(document, reader)

  lutaml_temp(document, reader)
end

Private Instance Methods

lutaml_temp(document, reader) click to toggle source
# File lib/metanorma/plugin/lutaml/lutaml_diagram_block.rb, line 23
def lutaml_temp(document, reader)
  temp_file = Tempfile.new(["lutaml", ".lutaml"], Utils.relative_file_path(document, ''))
  temp_file.puts(reader.read)
  temp_file.rewind
  temp_file
end