Sha256: b8676e9ebd2c180027d40e6b93f89edb8a86cd88d8414d840d96f6ff7faa894c

Contents?: true

Size: 496 Bytes

Versions: 5

Compression:

Stored size: 496 Bytes

Contents

class RiakCS < Fog::Bin
  class << self
    def class_for(key)
      case key
        when :provisioning
          Fog::RiakCS::Provisioning
        when :usage
          Fog::RiakCS::Usage
        else
          raise ArgumentError, "Unrecognized service: #{key}"
      end
    end

    def [](service)
      @@connections ||= Hash.new do |hash, key|
        hash[key] = class_for(key)
      end
      @@connections[service]
    end

    def services
      Fog::RiakCS.services
    end
  end
end

Version data entries

5 entries across 3 versions & 3 rubygems

Version Path
vagrant-packet-0.1.1 vendor/bundle/ruby/2.3.0/gems/fog-riakcs-0.1.0/lib/fog/bin/riakcs.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.4.0/gems/fog-riakcs-0.1.0/lib/fog/bin/riakcs.rb
vagrant-packet-0.1.1 vendor/bundle/ruby/2.5.0/gems/fog-riakcs-0.1.0/lib/fog/bin/riakcs.rb
vagrant-cloudstack-1.2.0 vendor/bundle/gems/fog-riakcs-0.1.0/lib/fog/bin/riakcs.rb
fog-riakcs-0.1.0 lib/fog/bin/riakcs.rb