Class: Proxmox::Task
Defined Under Namespace
Classes: Status
Instance Attribute Summary
Attributes inherited from Base
Instance Method Summary collapse
-
#initialize ⇒ Task
constructor
A new instance of Task.
- #inspect ⇒ Object
- #log(start: nil, limit: nil) ⇒ Object
- #rest_prefix ⇒ Object
- #status ⇒ Object
Methods inherited from Base
__new__, fetch, #method_missing, #refresh!, #respond_to?
Methods included from RestConnection
#bench, #rest_del, #rest_get, #rest_post, #rest_put
Constructor Details
#initialize ⇒ Task
Returns a new instance of Task.
271 272 273 274 |
# File 'lib/pve/proxmox.rb', line 271 def initialize rest_prefix @sid = upid end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Proxmox::Base
Instance Method Details
#inspect ⇒ Object
276 277 278 |
# File 'lib/pve/proxmox.rb', line 276 def inspect "#<#{self.class.name} #{@upid}>" end |
#log(start: nil, limit: nil) ⇒ Object
284 285 286 |
# File 'lib/pve/proxmox.rb', line 284 def log start: nil, limit: nil rest_get( "#{@rest_prefix}/log", start: start, limit: limit) end |
#rest_prefix ⇒ Object
267 268 269 |
# File 'lib/pve/proxmox.rb', line 267 def rest_prefix @rest_prefix = "/nodes/#{@node.node}/tasks/#{upid}" end |