otcextensions.sdk.vpc.v1.bandwidth¶
The VPC Bandwidth Class¶
The Bandwidth
class inherits from
Resource
.
- class otcextensions.sdk.vpc.v1.bandwidth.Bandwidth(_synchronized=False, connection=None, **attrs)¶
The base resource
- Parameters:
_synchronized (bool) – This is not intended to be used directly. See
new()
andexisting()
.connection (openstack.connection.Connection) – Reference to the Connection being used. Defaults to None to allow Resource objects to be used without an active Connection, such as in unit tests. Use of
self._connection
in Resource code should protect itself with a check for None.
- resources_key: ty.Optional[str] = 'bandwidths'¶
Plural form of key for resource.
- resource_key: ty.Optional[str] = 'bandwidth'¶
Singular form of key for resource.
- base_path: str = '/%(version)s/%(project_id)s/bandwidths'¶
The base part of the URI for this resource.
- allow_create = True¶
Allow create operation for this resource.
- allow_fetch = True¶
Allow get operation for this resource.
- allow_commit = True¶
Allow update operation for this resource.
- allow_delete = True¶
Allow delete operation for this resource.
- allow_list = True¶
Allow list operation for this resource.
- name: ty.Union[Body, URI]¶
Specifies the bandwidth name. Type: dict
- size¶
Specifies the bandwidth size. Type: dict
Specifies whether the bandwidth is shared or dedicated.
- publicip_info¶
Specifies the project ID.
- project_id¶
Specifies the project ID.
- bandwidth_type¶
Specifies the bandwidth type.
- charge_mode¶
Specifies that the bandwidth is billed by bandwidth.
- billing_info¶
Specifies the bill information.
- enterprise_project_id¶
Specifies the enterprise project ID.
- status¶
Specifies the bandwidth status.
- created_at¶
Specifies the time (UTC) when the bandwidth is created.
- updated_at¶
Specifies the time (UTC) when the bandwidth is updated.
- add_eip_to_bandwidth(session, version, publicip_info, project_id)¶
Method to add an EIP to shared bandwidth.
- Parameters:
session (
Adapter
) – The session to use for making this request.publicip_info (list) – List from dictionaries which describes eips.
- remove_eip_from_bandwidth(session, project_id, version, **attrs)¶
Method to remove an EIP from shared bandwidth.
- Parameters:
session (
Adapter
) – The session to use for making this request.attrs (dict) – Describes eip info.
- update_bandwidth(session, project_id, version, **attrs)¶
Method to update shared bandwidth.
- Parameters:
session (
Adapter
) – The session to use for making this request.attrs (kwargs) – Dictionary to udate bandwidth