# Class NetworkPolicy (0.12.0)

0.12.0 (latest) 0.11.0 0.4.0 0.3.0 0.2.0 0.1.8

    NetworkPolicy(mapping=None, *, ignore_unknown_fields=False, **kwargs)

Represents a Network Policy resource.

.. _oneof: <https://proto-plus-python.readthedocs.io/en/stable/fields.html#oneofs-mutually-exclusive-fields>

| ## Attributes ||
|---|---|
| **Name** | **Description** |
| `associations` | `MutableSequence[https://docs.cloud.google.com/python/docs/reference/google-cloud-compute-v1beta/latest/google.cloud.compute_v1beta.types.NetworkPolicyAssociation]` Output only. \[Output Only\] A list of associations that belong to this network policy. |
| `creation_timestamp` | `str` Output only. \[Output Only\] Creation timestamp inRFC3339 text format. This field is a member of `oneof`_ `_creation_timestamp`. |
| `description` | `str` An optional description of this resource. Provide this property when you create the resource. This field is a member of `oneof`_ `_description`. |
| `id` | `int` \[Output Only\] The unique identifier for the resource. This identifier is defined by the server. This field is a member of `oneof`_ `_id`. |
| `kind` | `str` Output only. \[Output only\] Type of the resource. Alwayscompute#networkPolicy for network policies This field is a member of `oneof`_ `_kind`. |
| `name` | `str` Name of the resource. This field is a member of `oneof`_ `_name`. |
| `region` | `str` Output only. \[Output Only\] URL of the region where the regional network policy resides. You must specify this field as part of the HTTP request URL. It is not settable as a field in the request body. This field is a member of `oneof`_ `_region`. |
| `rule_tuple_count` | `int` Output only. \[Output Only\] Total count of all network policy rule tuples. A network policy can not exceed a set number of tuples. This field is a member of `oneof`_ `_rule_tuple_count`. |
| `self_link` | `str` Output only. \[Output Only\] Server-defined URL for the resource. This field is a member of `oneof`_ `_self_link`. |
| `self_link_with_id` | `str` Output only. \[Output Only\] Server-defined URL for this resource with the resource id. This field is a member of `oneof`_ `_self_link_with_id`. |
| `traffic_classification_rules` | `MutableSequence[https://docs.cloud.google.com/python/docs/reference/google-cloud-compute-v1beta/latest/google.cloud.compute_v1beta.types.NetworkPolicyTrafficClassificationRule]` Output only. \[Output Only\] A list of traffic classification rules that belong to this policy. |