|
| 1 | +# -*- coding: utf-8 -*- |
| 2 | +# |
| 3 | +# Copyright 2019 Google LLC |
| 4 | +# |
| 5 | +# Licensed under the Apache License, Version 2.0 (the "License"); |
| 6 | +# you may not use this file except in compliance with the License. |
| 7 | +# You may obtain a copy of the License at |
| 8 | +# |
| 9 | +# https://www.apache.org/licenses/LICENSE-2.0 |
| 10 | +# |
| 11 | +# Unless required by applicable law or agreed to in writing, software |
| 12 | +# distributed under the License is distributed on an "AS IS" BASIS, |
| 13 | +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 14 | +# See the License for the specific language governing permissions and |
| 15 | +# limitations under the License. |
| 16 | + |
| 17 | +"""Wrappers for protocol buffer enum types.""" |
| 18 | + |
| 19 | +import enum |
| 20 | + |
| 21 | + |
| 22 | +class NullValue(enum.IntEnum): |
| 23 | + """ |
| 24 | + ``NullValue`` is a singleton enumeration to represent the null value |
| 25 | + for the ``Value`` type union. |
| 26 | +
|
| 27 | + The JSON representation for ``NullValue`` is JSON ``null``. |
| 28 | +
|
| 29 | + Attributes: |
| 30 | + NULL_VALUE (int): Null value. |
| 31 | + """ |
| 32 | + |
| 33 | + NULL_VALUE = 0 |
| 34 | + |
| 35 | + |
| 36 | +class Impact(object): |
| 37 | + class Category(enum.IntEnum): |
| 38 | + """ |
| 39 | + The category of the impact. |
| 40 | +
|
| 41 | + Attributes: |
| 42 | + CATEGORY_UNSPECIFIED (int): Default unspecified category. Don't use directly. |
| 43 | + COST (int): Indicates a potential increase or decrease in cost. |
| 44 | + SECURITY (int): Indicates a potential increase or decrease in security. |
| 45 | + PERFORMANCE (int): Indicates a potential increase or decrease in performance. |
| 46 | + MANAGEABILITY (int): Indicates a potential increase or decrease in manageability. |
| 47 | + """ |
| 48 | + |
| 49 | + CATEGORY_UNSPECIFIED = 0 |
| 50 | + COST = 1 |
| 51 | + SECURITY = 2 |
| 52 | + PERFORMANCE = 3 |
| 53 | + MANAGEABILITY = 4 |
| 54 | + |
| 55 | + |
| 56 | +class RecommendationStateInfo(object): |
| 57 | + class State(enum.IntEnum): |
| 58 | + """ |
| 59 | + Represents Recommendation State |
| 60 | +
|
| 61 | + Attributes: |
| 62 | + STATE_UNSPECIFIED (int): Default state. Don't use directly. |
| 63 | + ACTIVE (int): Recommendation is active and can be applied. Recommendations content can |
| 64 | + be updated by Google. |
| 65 | +
|
| 66 | + ACTIVE recommendations can be marked as CLAIMED, SUCCEEDED, or FAILED. |
| 67 | + CLAIMED (int): Recommendation is in claimed state. Recommendations content is |
| 68 | + immutable and cannot be updated by Google. |
| 69 | +
|
| 70 | + CLAIMED recommendations can be marked as CLAIMED, SUCCEEDED, or FAILED. |
| 71 | + SUCCEEDED (int): Recommendation is in succeeded state. Recommendations content is |
| 72 | + immutable and cannot be updated by Google. |
| 73 | +
|
| 74 | + SUCCEEDED recommendations can be marked as SUCCEEDED, or FAILED. |
| 75 | + FAILED (int): Recommendation is in failed state. Recommendations content is immutable |
| 76 | + and cannot be updated by Google. |
| 77 | +
|
| 78 | + FAILED recommendations can be marked as SUCCEEDED, or FAILED. |
| 79 | + DISMISSED (int): Recommendation is in dismissed state. Recommendation content can be |
| 80 | + updated by Google. |
| 81 | +
|
| 82 | + DISMISSED recommendations can be marked as ACTIVE. |
| 83 | + """ |
| 84 | + |
| 85 | + STATE_UNSPECIFIED = 0 |
| 86 | + ACTIVE = 1 |
| 87 | + CLAIMED = 6 |
| 88 | + SUCCEEDED = 3 |
| 89 | + FAILED = 4 |
| 90 | + DISMISSED = 5 |
0 commit comments