Class: OvirtSDK4::Job
- Inherits:
-
Identified
- Object
- Struct
- Identified
- OvirtSDK4::Job
- Defined in:
- lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb
Instance Method Summary collapse
-
#==(other) ⇒ Object
Returns
true
ifself
andother
have the same attributes and values. -
#auto_cleared ⇒ Boolean
Returns the value of the
auto_cleared
attribute. -
#auto_cleared=(value) ⇒ Object
Sets the value of the
auto_cleared
attribute. -
#comment ⇒ String
Returns the value of the
comment
attribute. -
#comment=(value) ⇒ Object
Sets the value of the
comment
attribute. -
#description ⇒ String
Returns the value of the
description
attribute. -
#description=(value) ⇒ Object
Sets the value of the
description
attribute. -
#end_time ⇒ DateTime
Returns the value of the
end_time
attribute. -
#end_time=(value) ⇒ Object
Sets the value of the
end_time
attribute. -
#external ⇒ Boolean
Returns the value of the
external
attribute. -
#external=(value) ⇒ Object
Sets the value of the
external
attribute. -
#hash ⇒ Object
Generates a hash value for this object.
-
#id ⇒ String
Returns the value of the
id
attribute. -
#id=(value) ⇒ Object
Sets the value of the
id
attribute. -
#initialize(opts = {}) ⇒ Job
constructor
Creates a new instance of the Job class.
-
#last_updated ⇒ DateTime
Returns the value of the
last_updated
attribute. -
#last_updated=(value) ⇒ Object
Sets the value of the
last_updated
attribute. -
#name ⇒ String
Returns the value of the
name
attribute. -
#name=(value) ⇒ Object
Sets the value of the
name
attribute. -
#owner ⇒ User
Returns the value of the
owner
attribute. -
#owner=(value) ⇒ Object
Sets the value of the
owner
attribute. -
#start_time ⇒ DateTime
Returns the value of the
start_time
attribute. -
#start_time=(value) ⇒ Object
Sets the value of the
start_time
attribute. -
#status ⇒ JobStatus
Returns the value of the
status
attribute. -
#status=(value) ⇒ Object
Sets the value of the
status
attribute. -
#steps ⇒ Array<Step>
Returns the value of the
steps
attribute. -
#steps=(list) ⇒ Object
Sets the value of the
steps
attribute.
Methods included from Type
Constructor Details
#initialize(opts = {}) ⇒ Job
Creates a new instance of the OvirtSDK4::Job class.
7479 7480 7481 7482 7483 7484 7485 7486 7487 7488 7489 |
# File 'lib/ovirtsdk4/types.rb', line 7479 def initialize(opts = {}) super(opts) self.auto_cleared = opts[:auto_cleared] self.end_time = opts[:end_time] self.external = opts[:external] self.last_updated = opts[:last_updated] self.owner = opts[:owner] self.start_time = opts[:start_time] self.status = opts[:status] self.steps = opts[:steps] end |
Instance Method Details
#==(other) ⇒ Object
Returns true
if self
and other
have the same attributes and values.
7494 7495 7496 7497 7498 7499 7500 7501 7502 7503 7504 |
# File 'lib/ovirtsdk4/types.rb', line 7494 def ==(other) super && @auto_cleared == other.auto_cleared && @end_time == other.end_time && @external == other.external && @last_updated == other.last_updated && @owner == other.owner && @start_time == other.start_time && @status == other.status && @steps == other.steps end |
#auto_cleared ⇒ Boolean
Returns the value of the auto_cleared
attribute.
7221 7222 7223 |
# File 'lib/ovirtsdk4/types.rb', line 7221 def auto_cleared @auto_cleared end |
#auto_cleared=(value) ⇒ Object
Sets the value of the auto_cleared
attribute.
7230 7231 7232 |
# File 'lib/ovirtsdk4/types.rb', line 7230 def auto_cleared=(value) @auto_cleared = value end |
#comment ⇒ String
Returns the value of the comment
attribute.
7239 7240 7241 |
# File 'lib/ovirtsdk4/types.rb', line 7239 def comment @comment end |
#comment=(value) ⇒ Object
Sets the value of the comment
attribute.
7248 7249 7250 |
# File 'lib/ovirtsdk4/types.rb', line 7248 def comment=(value) @comment = value end |
#description ⇒ String
Returns the value of the description
attribute.
7257 7258 7259 |
# File 'lib/ovirtsdk4/types.rb', line 7257 def description @description end |
#description=(value) ⇒ Object
Sets the value of the description
attribute.
7266 7267 7268 |
# File 'lib/ovirtsdk4/types.rb', line 7266 def description=(value) @description = value end |
#end_time ⇒ DateTime
Returns the value of the end_time
attribute.
7275 7276 7277 |
# File 'lib/ovirtsdk4/types.rb', line 7275 def end_time @end_time end |
#end_time=(value) ⇒ Object
Sets the value of the end_time
attribute.
7284 7285 7286 |
# File 'lib/ovirtsdk4/types.rb', line 7284 def end_time=(value) @end_time = value end |
#external ⇒ Boolean
Returns the value of the external
attribute.
7293 7294 7295 |
# File 'lib/ovirtsdk4/types.rb', line 7293 def external @external end |
#external=(value) ⇒ Object
Sets the value of the external
attribute.
7302 7303 7304 |
# File 'lib/ovirtsdk4/types.rb', line 7302 def external=(value) @external = value end |
#hash ⇒ Object
Generates a hash value for this object.
7509 7510 7511 7512 7513 7514 7515 7516 7517 7518 7519 |
# File 'lib/ovirtsdk4/types.rb', line 7509 def hash super + @auto_cleared.hash + @end_time.hash + @external.hash + @last_updated.hash + @owner.hash + @start_time.hash + @status.hash + @steps.hash end |
#id ⇒ String
Returns the value of the id
attribute.
7311 7312 7313 |
# File 'lib/ovirtsdk4/types.rb', line 7311 def id @id end |
#id=(value) ⇒ Object
Sets the value of the id
attribute.
7320 7321 7322 |
# File 'lib/ovirtsdk4/types.rb', line 7320 def id=(value) @id = value end |
#last_updated ⇒ DateTime
Returns the value of the last_updated
attribute.
7329 7330 7331 |
# File 'lib/ovirtsdk4/types.rb', line 7329 def last_updated @last_updated end |
#last_updated=(value) ⇒ Object
Sets the value of the last_updated
attribute.
7338 7339 7340 |
# File 'lib/ovirtsdk4/types.rb', line 7338 def last_updated=(value) @last_updated = value end |
#name ⇒ String
Returns the value of the name
attribute.
7347 7348 7349 |
# File 'lib/ovirtsdk4/types.rb', line 7347 def name @name end |
#name=(value) ⇒ Object
Sets the value of the name
attribute.
7356 7357 7358 |
# File 'lib/ovirtsdk4/types.rb', line 7356 def name=(value) @name = value end |
#owner ⇒ User
Returns the value of the owner
attribute.
7365 7366 7367 |
# File 'lib/ovirtsdk4/types.rb', line 7365 def owner @owner end |
#owner=(value) ⇒ Object
Sets the value of the owner
attribute.
The value
parameter can be an instance of User or a hash.
If it is a hash then a new instance will be created passing the hash as the
opts
parameter to the constructor.
7378 7379 7380 7381 7382 7383 |
# File 'lib/ovirtsdk4/types.rb', line 7378 def owner=(value) if value.is_a?(Hash) value = User.new(value) end @owner = value end |
#start_time ⇒ DateTime
Returns the value of the start_time
attribute.
7390 7391 7392 |
# File 'lib/ovirtsdk4/types.rb', line 7390 def start_time @start_time end |
#start_time=(value) ⇒ Object
Sets the value of the start_time
attribute.
7399 7400 7401 |
# File 'lib/ovirtsdk4/types.rb', line 7399 def start_time=(value) @start_time = value end |
#status ⇒ JobStatus
Returns the value of the status
attribute.
7408 7409 7410 |
# File 'lib/ovirtsdk4/types.rb', line 7408 def status @status end |
#status=(value) ⇒ Object
Sets the value of the status
attribute.
7417 7418 7419 |
# File 'lib/ovirtsdk4/types.rb', line 7417 def status=(value) @status = value end |
#steps ⇒ Array<Step>
Returns the value of the steps
attribute.
7426 7427 7428 |
# File 'lib/ovirtsdk4/types.rb', line 7426 def steps @steps end |
#steps=(list) ⇒ Object
Sets the value of the steps
attribute.
7435 7436 7437 7438 7439 7440 7441 7442 7443 7444 7445 |
# File 'lib/ovirtsdk4/types.rb', line 7435 def steps=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Step.new(value) end end end @steps = list end |