Sha256: 31edea917ab85a6b69473b9f67f763204d2dd8eefe79341fab1b020fa24f41ed

Contents?: true

Size: 273 Bytes

Versions: 24

Compression:

Stored size: 273 Bytes

Contents

module Infrataster
  module Resources
    class BaseResource
      # do nothing
      def name
        self.class.name.split('::').last[0...(-1 * 'Resource'.size)]
      end

      def context_class
        Contexts.const_get("#{name}Context")
      end
    end
  end
end

Version data entries

24 entries across 24 versions & 1 rubygems

Version Path
infrataster-0.3.2 lib/infrataster/resources/base_resource.rb
infrataster-0.3.1 lib/infrataster/resources/base_resource.rb
infrataster-0.3.0 lib/infrataster/resources/base_resource.rb
infrataster-0.2.6 lib/infrataster/resources/base_resource.rb
infrataster-0.2.5 lib/infrataster/resources/base_resource.rb
infrataster-0.2.4 lib/infrataster/resources/base_resource.rb
infrataster-0.2.3 lib/infrataster/resources/base_resource.rb
infrataster-0.2.2 lib/infrataster/resources/base_resource.rb
infrataster-0.2.1 lib/infrataster/resources/base_resource.rb
infrataster-0.2.0 lib/infrataster/resources/base_resource.rb
infrataster-0.2.0.beta1 lib/infrataster/resources/base_resource.rb
infrataster-0.1.13 lib/infrataster/resources/base_resource.rb
infrataster-0.1.12 lib/infrataster/resources/base_resource.rb
infrataster-0.1.11 lib/infrataster/resources/base_resource.rb
infrataster-0.1.10 lib/infrataster/resources/base_resource.rb
infrataster-0.1.9 lib/infrataster/resources/base_resource.rb
infrataster-0.1.8 lib/infrataster/resources/base_resource.rb
infrataster-0.1.7 lib/infrataster/resources/base_resource.rb
infrataster-0.1.6 lib/infrataster/resources/base_resource.rb
infrataster-0.1.5 lib/infrataster/resources/base_resource.rb