Creates a new instance of the {Step} class.
@param opts [Hash] A hash containing the attributes of the object. The keys of the hash
should be symbols corresponding to the names of the attributes. The values of the hash should be the values of the attributes.
@option opts [String] :comment The value of attribute `comment`.
@option opts [String] :description The value of attribute `description`.
@option opts [DateTime] :end_time The value of attribute `end_time`.
@option opts [Boolean] :external The value of attribute `external`.
@option opts [ExternalSystemType] :external_type The value of attribute `external_type`.
@option opts [String] :id The value of attribute `id`.
@option opts [Job, Hash] :job The value of attribute `job`.
@option opts [String] :name The value of attribute `name`.
@option opts [Integer] :number The value of attribute `number`.
@option opts [Step, Hash] :parent_step The value of attribute `parent_step`.
@option opts [Integer] :progress The value of attribute `progress`.
@option opts [DateTime] :start_time The value of attribute `start_time`.
@option opts [Array<Statistic>, Array<Hash>] :statistics The values of attribute `statistics`.
@option opts [StepStatus] :status The value of attribute `status`.
@option opts [StepEnum] :type The value of attribute `type`.
# File lib/ovirtsdk4/types.rb, line 18563 def initialize(opts = {}) super(opts) self.end_time = opts[:end_time] self.external = opts[:external] self.external_type = opts[:external_type] self.job = opts[:job] self.number = opts[:number] self.parent_step = opts[:parent_step] self.progress = opts[:progress] self.start_time = opts[:start_time] self.statistics = opts[:statistics] self.status = opts[:status] self.type = opts[:type] end
Returns `true` if `self` and `other` have the same attributes and values.
# File lib/ovirtsdk4/types.rb, line 18581 def ==(other) super && @end_time == other.end_time && @external == other.external && @external_type == other.external_type && @job == other.job && @number == other.number && @parent_step == other.parent_step && @progress == other.progress && @start_time == other.start_time && @statistics == other.statistics && @status == other.status && @type == other.type end
Returns the value of the `comment` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 18238 def comment @comment end
Sets the value of the `comment` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 18247 def comment=(value) @comment = value end
Returns the value of the `description` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 18256 def description @description end
Sets the value of the `description` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 18265 def description=(value) @description = value end
Returns the value of the `end_time` attribute.
@return [DateTime]
# File lib/ovirtsdk4/types.rb, line 18274 def end_time @end_time end
Sets the value of the `end_time` attribute.
@param value [DateTime]
# File lib/ovirtsdk4/types.rb, line 18283 def end_time=(value) @end_time = value end
Returns the value of the `external` attribute.
@return [Boolean]
# File lib/ovirtsdk4/types.rb, line 18292 def external @external end
Sets the value of the `external` attribute.
@param value [Boolean]
# File lib/ovirtsdk4/types.rb, line 18301 def external=(value) @external = value end
Returns the value of the `external_type` attribute.
@return [ExternalSystemType]
# File lib/ovirtsdk4/types.rb, line 18310 def external_type @external_type end
Sets the value of the `external_type` attribute.
@param value [ExternalSystemType]
# File lib/ovirtsdk4/types.rb, line 18319 def external_type=(value) @external_type = value end
Generates a hash value for this object.
# File lib/ovirtsdk4/types.rb, line 18599 def hash super + @end_time.hash + @external.hash + @external_type.hash + @job.hash + @number.hash + @parent_step.hash + @progress.hash + @start_time.hash + @statistics.hash + @status.hash + @type.hash end
Returns the value of the `id` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 18328 def id @id end
Sets the value of the `id` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 18337 def id=(value) @id = value end
Returns the value of the `job` attribute.
@return [Job]
# File lib/ovirtsdk4/types.rb, line 18346 def job @job end
Sets the value of the `job` attribute.
@param value [Job, Hash]
The `value` parameter can be an instance of {OvirtSDK4::Job} 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.
# File lib/ovirtsdk4/types.rb, line 18359 def job=(value) if value.is_a?(Hash) value = Job.new(value) end @job = value end
Returns the value of the `name` attribute.
@return [String]
# File lib/ovirtsdk4/types.rb, line 18371 def name @name end
Sets the value of the `name` attribute.
@param value [String]
# File lib/ovirtsdk4/types.rb, line 18380 def name=(value) @name = value end
Returns the value of the `number` attribute.
@return [Integer]
# File lib/ovirtsdk4/types.rb, line 18389 def number @number end
Sets the value of the `number` attribute.
@param value [Integer]
# File lib/ovirtsdk4/types.rb, line 18398 def number=(value) @number = value end
Returns the value of the `parent_step` attribute.
@return [Step]
# File lib/ovirtsdk4/types.rb, line 18407 def parent_step @parent_step end
Sets the value of the `parent_step` attribute.
@param value [Step, Hash]
The `value` parameter can be an instance of {OvirtSDK4::Step} 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.
# File lib/ovirtsdk4/types.rb, line 18420 def parent_step=(value) if value.is_a?(Hash) value = Step.new(value) end @parent_step = value end
Returns the value of the `progress` attribute.
@return [Integer]
# File lib/ovirtsdk4/types.rb, line 18432 def progress @progress end
Sets the value of the `progress` attribute.
@param value [Integer]
# File lib/ovirtsdk4/types.rb, line 18441 def progress=(value) @progress = value end
Returns the value of the `start_time` attribute.
@return [DateTime]
# File lib/ovirtsdk4/types.rb, line 18450 def start_time @start_time end
Sets the value of the `start_time` attribute.
@param value [DateTime]
# File lib/ovirtsdk4/types.rb, line 18459 def start_time=(value) @start_time = value end
Returns the value of the `statistics` attribute.
@return [Array<Statistic>]
# File lib/ovirtsdk4/types.rb, line 18468 def statistics @statistics end
Sets the value of the `statistics` attribute.
@param list [Array<Statistic>]
# File lib/ovirtsdk4/types.rb, line 18477 def statistics=(list) if list.class == Array list = List.new(list) list.each_with_index do |value, index| if value.is_a?(Hash) list[index] = Statistic.new(value) end end end @statistics = list end
Returns the value of the `status` attribute.
@return [StepStatus]
# File lib/ovirtsdk4/types.rb, line 18494 def status @status end
Sets the value of the `status` attribute.
@param value [StepStatus]
# File lib/ovirtsdk4/types.rb, line 18503 def status=(value) @status = value end
Returns the value of the `type` attribute.
@return [StepEnum]
# File lib/ovirtsdk4/types.rb, line 18512 def type @type end
Sets the value of the `type` attribute.
@param value [StepEnum]
# File lib/ovirtsdk4/types.rb, line 18521 def type=(value) @type = value end