Sha256: d62fc78d160f750ffb1624fbf84902ef5a6c7001023057db26d38ed5adf0d858

Contents?: true

Size: 380 Bytes

Versions: 1

Compression:

Stored size: 380 Bytes

Contents

# frozen_string_literal: true

module Tataru
  # class resource type pool
  class ResourceTypePool
    def initialize
      @pool = {}
    end

    def add_resource_desc(symbol, classconstant)
      @pool[symbol] = classconstant
    end

    def resource_desc_for(symbol)
      @pool[symbol]
    end

    def resource_desc_exist?(symbol)
      @pool.key? symbol
    end
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
tataru-0.2.0 lib/tataru/resource_type_pool.rb