Sha256: c82de501dcdad55d741de8f9bded4a69b580cbcda5cadf86116db06ff5adb98f

Contents?: true

Size: 673 Bytes

Versions: 5

Compression:

Stored size: 673 Bytes

Contents

# frozen_string_literal: true

module Thinreports
  module BasicReport
    module Core
      module Shape
        module Manager
          class Format < Core::Format::Base
            # @return [Symbol, Integer]
            attr_reader :identifier

            def initialize(config, id = nil, &block)
              super(config, &block)
              @identifier = id || object_id
            end

            def find_shape(id)
              shapes[id]
            end

            def has_shape?(id)
              shapes.key?(id)
            end

            def shapes
              @shapes ||= {}
            end
          end
        end
      end
    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
thinreports-0.14.2 lib/thinreports/basic_report/core/shape/manager/format.rb
thinreports-0.14.1 lib/thinreports/basic_report/core/shape/manager/format.rb
thinreports-0.14.0 lib/thinreports/basic_report/core/shape/manager/format.rb
thinreports-0.13.1 lib/thinreports/basic_report/core/shape/manager/format.rb
thinreports-0.13.0 lib/thinreports/basic_report/core/shape/manager/format.rb