Class: OvirtSDK4::OpenStackSubnet

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

- (OpenStackSubnet) initialize(opts = {})

Creates a new instance of the OvirtSDK4::OpenStackSubnet 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):

  • :cidr (String)

    The value of attribute cidr.

  • :comment (String)

    The value of attribute comment.

  • :description (String)

    The value of attribute description.

  • :dns_servers (Array<String>, Array<Hash>)

    The values of attribute dns_servers.

  • :gateway (String)

    The value of attribute gateway.

  • :id (String)

    The value of attribute id.

  • :ip_version (String)

    The value of attribute ip_version.

  • :name (String)

    The value of attribute name.

  • :openstack_network (OpenStackNetwork, Hash)

    The value of attribute openstack_network.



8912
8913
8914
8915
8916
8917
8918
8919
8920
8921
8922
8923
# File 'lib/ovirtsdk4/types.rb', line 8912

def initialize(opts = {})
  super(opts)
  self.cidr = opts[:cidr]
  self.comment = opts[:comment]
  self.description = opts[:description]
  self.dns_servers = opts[:dns_servers]
  self.gateway = opts[:gateway]
  self.id = opts[:id]
  self.ip_version = opts[:ip_version]
  self.name = opts[:name]
  self.openstack_network = opts[:openstack_network]
end

Instance Method Details

- (String) cidr

Returns the value of the cidr attribute.

Returns:

  • (String)


8723
8724
8725
# File 'lib/ovirtsdk4/types.rb', line 8723

def cidr
  return @cidr
end

- (Object) cidr=(value)

Sets the value of the cidr attribute.

Parameters:

  • value (String)


8732
8733
8734
# File 'lib/ovirtsdk4/types.rb', line 8732

def cidr=(value)
  @cidr = value
end

- (String) comment

Returns the value of the comment attribute.

Returns:

  • (String)


8741
8742
8743
# File 'lib/ovirtsdk4/types.rb', line 8741

def comment
  return @comment
end

- (Object) comment=(value)

Sets the value of the comment attribute.

Parameters:

  • value (String)


8750
8751
8752
# File 'lib/ovirtsdk4/types.rb', line 8750

def comment=(value)
  @comment = value
end

- (String) description

Returns the value of the description attribute.

Returns:

  • (String)


8759
8760
8761
# File 'lib/ovirtsdk4/types.rb', line 8759

def description
  return @description
end

- (Object) description=(value)

Sets the value of the description attribute.

Parameters:

  • value (String)


8768
8769
8770
# File 'lib/ovirtsdk4/types.rb', line 8768

def description=(value)
  @description = value
end

- (Array<String>) dns_servers

Returns the value of the dns_servers attribute.

Returns:

  • (Array<String>)


8777
8778
8779
# File 'lib/ovirtsdk4/types.rb', line 8777

def dns_servers
  return @dns_servers
end

- (Object) dns_servers=(list)

Sets the value of the dns_servers attribute.

Parameters:

  • list (Array<String>)


8785
8786
8787
# File 'lib/ovirtsdk4/types.rb', line 8785

def dns_servers=(list)
  @dns_servers = list
end

- (String) gateway

Returns the value of the gateway attribute.

Returns:

  • (String)


8794
8795
8796
# File 'lib/ovirtsdk4/types.rb', line 8794

def gateway
  return @gateway
end

- (Object) gateway=(value)

Sets the value of the gateway attribute.

Parameters:

  • value (String)


8803
8804
8805
# File 'lib/ovirtsdk4/types.rb', line 8803

def gateway=(value)
  @gateway = value
end

- (String) id

Returns the value of the id attribute.

Returns:

  • (String)


8812
8813
8814
# File 'lib/ovirtsdk4/types.rb', line 8812

def id
  return @id
end

- (Object) id=(value)

Sets the value of the id attribute.

Parameters:

  • value (String)


8821
8822
8823
# File 'lib/ovirtsdk4/types.rb', line 8821

def id=(value)
  @id = value
end

- (String) ip_version

Returns the value of the ip_version attribute.

Returns:

  • (String)


8830
8831
8832
# File 'lib/ovirtsdk4/types.rb', line 8830

def ip_version
  return @ip_version
end

- (Object) ip_version=(value)

Sets the value of the ip_version attribute.

Parameters:

  • value (String)


8839
8840
8841
# File 'lib/ovirtsdk4/types.rb', line 8839

def ip_version=(value)
  @ip_version = value
end

- (String) name

Returns the value of the name attribute.

Returns:

  • (String)


8848
8849
8850
# File 'lib/ovirtsdk4/types.rb', line 8848

def name
  return @name
end

- (Object) name=(value)

Sets the value of the name attribute.

Parameters:

  • value (String)


8857
8858
8859
# File 'lib/ovirtsdk4/types.rb', line 8857

def name=(value)
  @name = value
end

- (OpenStackNetwork) openstack_network

Returns the value of the openstack_network attribute.

Returns:



8866
8867
8868
# File 'lib/ovirtsdk4/types.rb', line 8866

def openstack_network
  return @openstack_network
end

- (Object) openstack_network=(value)

Sets the value of the openstack_network attribute.

The value parameter can be an instance of OvirtSDK4::OpenStackNetwork 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:



8879
8880
8881
8882
8883
8884
# File 'lib/ovirtsdk4/types.rb', line 8879

def openstack_network=(value)
  if value.is_a?(Hash)
    value = OpenStackNetwork.new(value)
  end
  @openstack_network = value
end