Class: Fog::Compute::Cloudstack::Job

Inherits:
Model
  • Object
show all
Defined in:
lib/rackspace-fog/cloudstack/models/compute/job.rb

Instance Attribute Summary

Attributes inherited from Model

#collection, #connection

Instance Method Summary collapse

Methods inherited from Model

#initialize, #inspect, #symbolize_keys, #to_json, #wait_for

Methods included from Attributes::ClassMethods

#_load, #aliases, #attribute, #attributes, #identity, #ignore_attributes, #ignored_attributes

Methods included from Attributes::InstanceMethods

#_dump, #attributes, #dup, #identity, #identity=, #merge_attributes, #new_record?, #requires, #requires_one

Constructor Details

This class inherits a constructor from Fog::Model

Instance Method Details

#finished?Boolean

Returns:

  • (Boolean)


23
24
25
# File 'lib/rackspace-fog/cloudstack/models/compute/job.rb', line 23

def finished?
  self.job_status != 0
end

#reloadObject



18
19
20
21
# File 'lib/rackspace-fog/cloudstack/models/compute/job.rb', line 18

def reload
  requires :id
  merge_attributes(connection.query_async_job_result('jobid' => self.id)['queryasyncjobresultresponse'])
end