Sha256: 7e81bcf863f742161052cd786f89ac0c6858bb7b4a4a9f26960f17b5e37cb5d7

Contents?: true

Size: 649 Bytes

Versions: 4

Compression:

Stored size: 649 Bytes

Contents

require 'fog/compute/gridscale/models/paging_collection'

module Fog
  module Compute
    class Gridscale
      class PaasServices < Fog::Compute::Gridscale::PagingCollection
        model Fog::Compute::Gridscale::PaasService

        def all(filters={})
          data = service.paas_services_get(filters)
          droplets = data.body["paas_services"].values
          load(droplets)
        end

        def get(object_uuid)
          paas_service = service.paas_service_get(object_uuid).body['paas_service']
          new(paas_service) if paas_service
        rescue Fog::Errors::NotFound
          nil
        end

      end
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
fog-gridscale-0.1.5 lib/fog/compute/gridscale/models/paas_services.rb
fog-gridscale-0.1.4 lib/fog/compute/gridscale/models/paas_services.rb
fog-gridscale-0.1.3 lib/fog/compute/gridscale/models/paas_services.rb
fog-gridscale-0.1.2 lib/fog/compute/gridscale/models/paas_services.rb