Class: OvirtSDK4::File

Inherits:
Identified show all
Defined in:
lib/ovirtsdk4/types.rb,
lib/ovirtsdk4/types.rb

Instance Method Summary (collapse)

Methods included from Type

#href, #href=

Constructor Details

- (File) initialize(opts = {})

Creates a new instance of the OvirtSDK4::File class.

Parameters:

  • opts (Hash) (defaults to: {})

    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.

Options Hash (opts):

  • :comment (String)

    The value of attribute comment.

  • :content (String)

    The value of attribute content.

  • :description (String)

    The value of attribute description.

  • :id (String)

    The value of attribute id.

  • :name (String)

    The value of attribute name.

  • :storage_domain (StorageDomain, Hash)

    The value of attribute storage_domain.

  • :type (String)

    The value of attribute type.



29638
29639
29640
29641
29642
29643
29644
29645
29646
29647
# File 'lib/ovirtsdk4/types.rb', line 29638

def initialize(opts = {})
  super(opts)
  self.comment = opts[:comment]
  self.content = opts[:content]
  self.description = opts[:description]
  self.id = opts[:id]
  self.name = opts[:name]
  self.storage_domain = opts[:storage_domain]
  self.type = opts[:type]
end

Instance Method Details

- (String) comment

Returns the value of the comment attribute.

Returns:

  • (String)


29488
29489
29490
# File 'lib/ovirtsdk4/types.rb', line 29488

def comment
  return @comment
end

- (Object) comment=(value)

Sets the value of the comment attribute.

Parameters:

  • value (String)


29497
29498
29499
# File 'lib/ovirtsdk4/types.rb', line 29497

def comment=(value)
  @comment = value
end

- (String) content

Returns the value of the content attribute.

Returns:

  • (String)


29506
29507
29508
# File 'lib/ovirtsdk4/types.rb', line 29506

def content
  return @content
end

- (Object) content=(value)

Sets the value of the content attribute.

Parameters:

  • value (String)


29515
29516
29517
# File 'lib/ovirtsdk4/types.rb', line 29515

def content=(value)
  @content = value
end

- (String) description

Returns the value of the description attribute.

Returns:

  • (String)


29524
29525
29526
# File 'lib/ovirtsdk4/types.rb', line 29524

def description
  return @description
end

- (Object) description=(value)

Sets the value of the description attribute.

Parameters:

  • value (String)


29533
29534
29535
# File 'lib/ovirtsdk4/types.rb', line 29533

def description=(value)
  @description = value
end

- (String) id

Returns the value of the id attribute.

Returns:

  • (String)


29542
29543
29544
# File 'lib/ovirtsdk4/types.rb', line 29542

def id
  return @id
end

- (Object) id=(value)

Sets the value of the id attribute.

Parameters:

  • value (String)


29551
29552
29553
# File 'lib/ovirtsdk4/types.rb', line 29551

def id=(value)
  @id = value
end

- (String) name

Returns the value of the name attribute.

Returns:

  • (String)


29560
29561
29562
# File 'lib/ovirtsdk4/types.rb', line 29560

def name
  return @name
end

- (Object) name=(value)

Sets the value of the name attribute.

Parameters:

  • value (String)


29569
29570
29571
# File 'lib/ovirtsdk4/types.rb', line 29569

def name=(value)
  @name = value
end

- (StorageDomain) storage_domain

Returns the value of the storage_domain attribute.

Returns:



29578
29579
29580
# File 'lib/ovirtsdk4/types.rb', line 29578

def storage_domain
  return @storage_domain
end

- (Object) storage_domain=(value)

Sets the value of the storage_domain attribute.

The value parameter can be an instance of StorageDomain 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.

Parameters:



29591
29592
29593
29594
29595
29596
# File 'lib/ovirtsdk4/types.rb', line 29591

def storage_domain=(value)
  if value.is_a?(Hash)
    value = StorageDomain.new(value)
  end
  @storage_domain = value
end

- (String) type

Returns the value of the type attribute.

Returns:

  • (String)


29603
29604
29605
# File 'lib/ovirtsdk4/types.rb', line 29603

def type
  return @type
end

- (Object) type=(value)

Sets the value of the type attribute.

Parameters:

  • value (String)


29612
29613
29614
# File 'lib/ovirtsdk4/types.rb', line 29612

def type=(value)
  @type = value
end