Sha256: e72f1d31cd55ddecbcd2e6b6817690bee38651a333aec1fbe2d7bf9d4db2b933

Contents?: true

Size: 859 Bytes

Versions: 2

Compression:

Stored size: 859 Bytes

Contents

require_relative 'abstract_writer'

module Cuker
  class RubyXLWriter < AbstractWriter
    def initialize
      super
      @log.debug "initing #{self.class}"
    end

    def write_title title_ary
      @log.debug "Rxl write title"
      @active_sheet.add_row title_ary
    end

    def write_new_row row_ary
      @log.debug "Rxl write row"
      @active_sheet.add_row row_ary
    end

    def make_new_sheet name = nil
      @log.debug "Rxl make new sheet"
      path = super name
      @sheets[name] = RubyXLSheet.new path
    end

    def make_new_file name
      super name
    end

    class RubyXLSheet < AbstractSheet
      def initialize file_name
        super file_name
        @log.info "Making new #{self.class} => #{file_name}"
        # @jira_file = File.open(file_name, "wb")
      end

    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cuker-0.5.3 lib/cuker/helpers/writers/ruby_x_l_writer.rb
cuker-0.4.9 lib/cuker/helpers/writers/ruby_x_l_writer.rb