Sha256: 3cb81e37f529d6f21fb8434f99c18a50d2ef8cb0a4d47c5325469d51b1c4c6c1

Contents?: true

Size: 569 Bytes

Versions: 25

Compression:

Stored size: 569 Bytes

Contents

require 'fog/ecloud/models/compute/task'

module Fog
  module Compute
    class Ecloud

      class Tasks < Fog::Ecloud::Collection

        model Fog::Compute::Ecloud::Task

        attribute :href, :aliases => :Href

        def all
          check_href!
          if data = connection.get_task_list(href).body[:Task]
            load(data)
          end
        end

        def get(uri)
          if data = connection.get_task(uri)
            new(data.body)
          end
        rescue Fog::Errors::NotFound
          nil
        end

      end
    end
  end
end

Version data entries

25 entries across 25 versions & 7 rubygems

Version Path
brightbox-cli-0.15.0 lib/brightbox-cli/vendor/fog/lib/fog/ecloud/models/compute/tasks.rb
tag-fog-1.0.1 lib/fog/ecloud/models/compute/tasks.rb
brightbox-cli-0.14.1 lib/brightbox-cli/vendor/fog/lib/fog/ecloud/models/compute/tasks.rb
brightbox-cli-0.14.0 lib/brightbox-cli/vendor/fog/lib/fog/ecloud/models/compute/tasks.rb
fog-1.0.0 lib/fog/ecloud/models/compute/tasks.rb