Sha256: 0e6bef902bc3c7c4e15cb89c4afae80c18a3a162d1958064ee459371ffbcb082

Contents?: true

Size: 455 Bytes

Versions: 7

Compression:

Stored size: 455 Bytes

Contents

module Lionel
  class ProxyWorksheet
    extend Forwardable

    def_delegators :worksheet, :rows, :save
    def_delegators :rows, :size

    attr_reader :worksheet
    def initialize(worksheet)
      @worksheet = worksheet
    end

    def []=(col, row, value)
      worksheet["#{col}#{row}"] = value
    end

    def [](col, row)
      worksheet["#{col}#{row}"]
    end

    HEADER_ROW = 1
    def content_rows
      rows(HEADER_ROW)
    end

  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
lionel_richie-0.3.1 lib/lionel/proxy_worksheet.rb
lionel_richie-0.3.0 lib/lionel/proxy_worksheet.rb
lionel_richie-0.2.4 lib/lionel/proxy_worksheet.rb
lionel_richie-0.2.3.1 lib/lionel/proxy_worksheet.rb
lionel_richie-0.2.3 lib/lionel/proxy_worksheet.rb
lionel_richie-0.2.1 lib/lionel/proxy_worksheet.rb
lionel_richie-0.2.0 lib/lionel/proxy_worksheet.rb