Skip to content

Commit

Permalink
docs: Add documentation for enums (#249)
Browse files Browse the repository at this point in the history
* docs: Add documentation for enums

fix: Add context manager return types

chore: Update gapic-generator-python to v1.8.1
PiperOrigin-RevId: 503210727

Source-Link: googleapis/googleapis@a391fd1

Source-Link: googleapis/googleapis-gen@0080f83
Copy-Tag: eyJwIjoiLmdpdGh1Yi8uT3dsQm90LnlhbWwiLCJoIjoiMDA4MGY4MzBkZWMzN2MzMzg0MTU3MDgyYmNlMjc5ZTM3MDc5ZWE1OCJ9

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

* 🦉 Updates from OwlBot post-processor

See https://github.com/googleapis/repo-automation-bots/blob/main/packages/owl-bot/README.md

Co-authored-by: Owl Bot <gcf-owl-bot[bot]@users.noreply.github.com>
  • Loading branch information
gcf-owl-bot[bot] and gcf-owl-bot[bot] authored Jan 23, 2023
1 parent 237fe3a commit 4bff8bf
Show file tree
Hide file tree
Showing 6 changed files with 76 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -904,7 +904,7 @@ def sample_create_submission():
# Done; return the response.
return response

def __enter__(self):
def __enter__(self) -> "WebRiskServiceClient":
return self

def __exit__(self, type, value, traceback):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,20 @@
class ThreatType(proto.Enum):
r"""The type of threat. This maps directly to the threat list a
threat may belong to.
Values:
THREAT_TYPE_UNSPECIFIED (0):
No entries should match this threat type.
This threat type is unused.
MALWARE (1):
Malware targeting any platform.
SOCIAL_ENGINEERING (2):
Social engineering targeting any platform.
UNWANTED_SOFTWARE (3):
Unwanted software targeting any platform.
SOCIAL_ENGINEERING_EXTENDED_COVERAGE (4):
A list of extended coverage social
engineering URIs targeting any platform.
"""
THREAT_TYPE_UNSPECIFIED = 0
MALWARE = 1
Expand All @@ -52,7 +66,16 @@ class ThreatType(proto.Enum):


class CompressionType(proto.Enum):
r"""The ways in which threat entry sets can be compressed."""
r"""The ways in which threat entry sets can be compressed.
Values:
COMPRESSION_TYPE_UNSPECIFIED (0):
Unknown.
RAW (1):
Raw, uncompressed data.
RICE (2):
Rice-Golomb encoded data.
"""
COMPRESSION_TYPE_UNSPECIFIED = 0
RAW = 1
RICE = 2
Expand Down Expand Up @@ -168,7 +191,20 @@ class ComputeThreatListDiffResponse(proto.Message):
"""

class ResponseType(proto.Enum):
r"""The type of response sent to the client."""
r"""The type of response sent to the client.
Values:
RESPONSE_TYPE_UNSPECIFIED (0):
Unknown.
DIFF (1):
Partial updates are applied to the client's
existing local database.
RESET (2):
Full updates resets the client's entire local
database. This means that either the client had
no state, was seriously out-of-date, or the
client is believed to be corrupt.
"""
RESPONSE_TYPE_UNSPECIFIED = 0
DIFF = 1
RESET = 2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -752,7 +752,7 @@ def sample_search_hashes():
# Done; return the response.
return response

def __enter__(self):
def __enter__(self) -> "WebRiskServiceV1Beta1Client":
return self

def __exit__(self, type, value, traceback):
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,16 @@
class ThreatType(proto.Enum):
r"""The type of threat. This maps dirrectly to the threat list a
threat may belong to.
Values:
THREAT_TYPE_UNSPECIFIED (0):
Unknown.
MALWARE (1):
Malware targeting any platform.
SOCIAL_ENGINEERING (2):
Social engineering targeting any platform.
UNWANTED_SOFTWARE (3):
Unwanted software targeting any platform.
"""
THREAT_TYPE_UNSPECIFIED = 0
MALWARE = 1
Expand All @@ -49,7 +59,16 @@ class ThreatType(proto.Enum):


class CompressionType(proto.Enum):
r"""The ways in which threat entry sets can be compressed."""
r"""The ways in which threat entry sets can be compressed.
Values:
COMPRESSION_TYPE_UNSPECIFIED (0):
Unknown.
RAW (1):
Raw, uncompressed data.
RICE (2):
Rice-Golomb encoded data.
"""
COMPRESSION_TYPE_UNSPECIFIED = 0
RAW = 1
RICE = 2
Expand Down Expand Up @@ -154,7 +173,20 @@ class ComputeThreatListDiffResponse(proto.Message):
"""

class ResponseType(proto.Enum):
r"""The type of response sent to the client."""
r"""The type of response sent to the client.
Values:
RESPONSE_TYPE_UNSPECIFIED (0):
Unknown.
DIFF (1):
Partial updates are applied to the client's
existing local database.
RESET (2):
Full updates resets the client's entire local
database. This means that either the client had
no state, was seriously out-of-date, or the
client is believed to be corrupt.
"""
RESPONSE_TYPE_UNSPECIFIED = 0
DIFF = 1
RESET = 2
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
],
"language": "PYTHON",
"name": "google-cloud-webrisk",
"version": "1.10.0"
"version": "0.1.0"
},
"snippets": [
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
],
"language": "PYTHON",
"name": "google-cloud-webrisk",
"version": "1.10.0"
"version": "0.1.0"
},
"snippets": [
{
Expand Down

0 comments on commit 4bff8bf

Please sign in to comment.