cfme.networks.subnet module

class cfme.networks.subnet.AddSubnet(obj, navigate_obj)[source]

Bases: cfme.utils.appliance.implementations.ui.CFMENavigateStep

VIEW

alias of SubnetAddView

prerequisite

This is a helper descriptor for navigation destinations which are linked to the same class.

For instance, imagine you have an object that has a ‘ViewAll’, destination that needs to be visited before you can click on ‘New’. In this instance, you would need to make the ‘New’ destination use ‘ViewAll’ as a prerequisite. As this would need no other special input, we can use NavigateToSibling as a helper. This will set prerequisite to be a callable that will navigate to the prerequisite step.

step()[source]
class cfme.networks.subnet.All(obj, navigate_obj)[source]

Bases: cfme.utils.appliance.implementations.ui.CFMENavigateStep

VIEW

alias of SubnetView

prerequisite

This is a helper descriptor for destinations which are linked to an attribute of the object.

For instance, imagine you have an object that has an attribute(parent) which has a ‘ViewAll’, destination that needs to be visited before you can click on ‘New’. In this instance, you would need to make the ‘New’ destination use ‘ViewAll’ as a prerequisite. As this would need no other special input, we can use NavigateToAttribute as a helper, supplying only the name of the attribute which stores the object to be used in the navigation, and the destination name. This will set prerequisite to be a callable that will navigate to the prerequisite step.

step()[source]
class cfme.networks.subnet.EditSubnet(obj, navigate_obj)[source]

Bases: cfme.utils.appliance.implementations.ui.CFMENavigateStep

VIEW

alias of SubnetEditView

prerequisite

This is a helper descriptor for navigation destinations which are linked to the same class.

For instance, imagine you have an object that has a ‘ViewAll’, destination that needs to be visited before you can click on ‘New’. In this instance, you would need to make the ‘New’ destination use ‘ViewAll’ as a prerequisite. As this would need no other special input, we can use NavigateToSibling as a helper. This will set prerequisite to be a callable that will navigate to the prerequisite step.

step()[source]
class cfme.networks.subnet.OpenCloudNetworks(obj, navigate_obj)[source]

Bases: cfme.utils.appliance.implementations.ui.CFMENavigateStep

VIEW

alias of SubnetDetailsView

prerequisite

This is a helper descriptor for destinations which are linked to an attribute of the object.

For instance, imagine you have an object that has an attribute(parent) which has a ‘ViewAll’, destination that needs to be visited before you can click on ‘New’. In this instance, you would need to make the ‘New’ destination use ‘ViewAll’ as a prerequisite. As this would need no other special input, we can use NavigateToAttribute as a helper, supplying only the name of the attribute which stores the object to be used in the navigation, and the destination name. This will set prerequisite to be a callable that will navigate to the prerequisite step.

step()[source]
class cfme.networks.subnet.Subnet(parent, name, provider_obj, network)[source]

Bases: cfme.common.WidgetasticTaggable, cfme.modeling.base.BaseEntity

Class representing subnets in sdn

__eq__(other)

Automatically created by attrs.

__ge__(other)

Automatically created by attrs.

__gt__(other)

Automatically created by attrs.

__le__(other)

Automatically created by attrs.

__lt__(other)

Automatically created by attrs.

__ne__(other)

Automatically created by attrs.

__repr__()

Automatically created by attrs.

category = 'networks'
cidr

Return subnet’s CIDR

cloud_network

Return name of network that subnet belongs to

cloud_tenant

Return name of tenant that subnet belongs to

db_types = ['NetworkSubnet']
delete()[source]

Deletes this subnet

edit(new_name, gateway=None)[source]

Edit cloud subnet

Parameters:
  • new_name – (str) new name of subnet
  • gateway – (str) IP of new gateway, for example: 11.11.11.1
exists
in_version = ('5.8', Version('master'))
name = Attribute(name='name', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, convert=None, metadata=mappingproxy({}))
net_protocol

Return subnet’s network protocol

network = Attribute(name='network', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, convert=None, metadata=mappingproxy({}))
network_provider

Returns network provider

parent_provider

Return object of parent cloud provider

provider
provider_obj = Attribute(name='provider_obj', default=NOTHING, validator=None, repr=True, cmp=True, hash=None, init=True, convert=None, metadata=mappingproxy({}))
quad_name = None
string_name = 'NetworkSubnet'
zone
class cfme.networks.subnet.SubnetCollection(parent, filters=NOTHING)[source]

Bases: cfme.modeling.base.BaseCollection

Collection object for Subnet object Note: Network providers object are not implemented in mgmt

ENTITY

alias of Subnet

__eq__(other)

Automatically created by attrs.

__ge__(other)

Automatically created by attrs.

__gt__(other)

Automatically created by attrs.

__le__(other)

Automatically created by attrs.

__lt__(other)

Automatically created by attrs.

__ne__(other)

Automatically created by attrs.

__repr__()

Automatically created by attrs.

all()[source]
create(name, tenant, provider, network_manager, network_name, cidr, gateway=None)[source]

Create subnet

Parameters:
  • name – (str) name of the subnet
  • tenant – (str) name of the tenant to place subnet to
  • provider – crud object of Openstack cloud provider
  • network_manager – (str) name of network manager
  • network_name – (str) name of the network to create subnet under
  • cidr – (str) CIDR of subnet, for example: 192.168.12.2/24
  • gateway – (str) gateway of subnet, if None - appliance will set it automatically

Returns: instance of cfme.newtorks.subnet.Subnet