Method: IsoDoc::XslfoPdfConvert#input_xml_path

Defined in:
lib/isodoc/xslfo_convert.rb

#input_xml_path(input_filename, xml_file, debug) ⇒ Object



71
72
73
74
75
76
77
78
79
80
81
82
83
# File 'lib/isodoc/xslfo_convert.rb', line 71

def input_xml_path(input_filename, xml_file, debug)
  docxml, filename, dir = convert_init(xml_file, input_filename, debug)
  unless /\.xml$/.match?(input_filename)
    input_filename = Tempfile.open([filename, ".xml"],
                                   encoding: "utf-8") do |f|
      f.write xml_file
      f.path
    end
  end
  FileUtils.rm_rf dir

  [input_filename, docxml, filename]
end