1 # ============LICENSE_START===============================================
2 # Copyright (C) 2023 Nordix Foundation. All rights reserved.
3 # ========================================================================
4 # Licensed under the Apache License, Version 2.0 (the "License");
5 # you may not use this file except in compliance with the License.
6 # You may obtain a copy of the License at
8 # http://www.apache.org/licenses/LICENSE-2.0
10 # Unless required by applicable law or agreed to in writing, software
11 # distributed under the License is distributed on an "AS IS" BASIS,
12 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 # See the License for the specific language governing permissions and
14 # limitations under the License.
15 # ============LICENSE_END=================================================
20 from __future__ import absolute_import
21 from datetime import date, datetime # noqa: F401
23 from typing import List, Dict # noqa: F401
26 class EnforceStatus():
28 def __init__(self, enforce_status: str=None, enforce_reason: str=None): # noqa: E501
31 :param enforce_status: The enforce_status of this EnforceStatus. # noqa: E501
32 :type enforce_status: str
33 :param enforce_reason: The enforce_reason of this EnforceStatus. # noqa: E501
34 :type enforce_reason: str
36 self._enforce_status = enforce_status
37 self._enforce_reason = enforce_reason
40 def enforce_status(self) -> str:
41 """Gets the enforce_status of this EnforceStatus.
43 :return: The enforce_status of this EnforceStatus.
46 return self._enforce_status
48 @enforce_status.setter
49 def enforce_status(self, enforce_status: str):
50 """Sets the enforce_status of this EnforceStatus.
52 :param enforce_status: The enforce_status of this EnforceStatus.
53 :type enforce_status: str
55 allowed_values = ["ENFORCED", "NOT_ENFORCED"] # noqa: E501
56 if enforce_status not in allowed_values:
58 "Invalid value for `enforce_status` ({0}), must be one of {1}"
59 .format(enforce_status, allowed_values)
62 self._enforce_status = enforce_status
65 def enforce_reason(self) -> str:
66 """Gets the enforce_reason of this EnforceStatus.
68 :return: The enforce_reason of this EnforceStatus.
71 return self._enforce_reason
73 @enforce_reason.setter
74 def enforce_reason(self, enforce_reason: str):
75 """Sets the enforce_reason of this EnforceStatus.
77 :param enforce_reason: The enforce_reason of this EnforceStatus.
78 :type enforce_reason: str
80 allowed_values = ["SCOPE_NOT_APPLICABLE", "STATEMENT_NOT_APPLICABLE", "OTHER_REASON"] # noqa: E501
81 if enforce_reason not in allowed_values:
83 "Invalid value for `enforce_reason` ({0}), must be one of {1}"
84 .format(enforce_reason, allowed_values)
87 self._enforce_reason = enforce_reason
90 """Returns the model properties as a dict
95 'enforceStatus': self._enforce_status,
96 'enforceReason': self._enforce_reason