Sha256: d87a3143ea3360dfe6c5717fca652bd4a374e191a049fa9237af1406b92fb985

Contents?: true

Size: 779 Bytes

Versions: 8

Compression:

Stored size: 779 Bytes

Contents

require "metanorma/processor"

module Metanorma
  module Csand
    class Processor < Metanorma::Processor

      def initialize
        @short = :csand
        @input_format = :asciidoc
        @asciidoctor_backend = :csand
      end

      def output_formats
        super.merge(
          html: "html"
        )
      end

      def version
        "Asciidoctor::Csand #{Asciidoctor::Csand::VERSION}"
      end

      def input_to_isodoc(file)
        Metanorma::Input::Asciidoc.new.process(file, @asciidoctor_backend)
      end

      def output(isodoc_node, outname, format, options={})
        case format
        when :html
          IsoDoc::Csand::HtmlConvert.new(options).convert(outname, isodoc_node)
        else
          super
        end
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
metanorma-csand-1.0.4 lib/metanorma/csand/processor.rb
metanorma-csand-1.0.3 lib/metanorma/csand/processor.rb
metanorma-csand-1.0.2 lib/metanorma/csand/processor.rb
metanorma-csand-1.0.1 lib/metanorma/csand/processor.rb
metanorma-csand-1.0.0 lib/metanorma/csand/processor.rb
asciidoctor-csand-0.3.4 lib/metanorma/csand/processor.rb
asciidoctor-csand-0.3.3 lib/metanorma/csand/processor.rb
asciidoctor-csand-0.3.2 lib/metanorma/csand/processor.rb