1# coding: utf-8 2# Copyright (c) 2016, 2021, Oracle and/or its affiliates. All rights reserved. 3# This software is dual-licensed to you under the Universal Permissive License (UPL) 1.0 as shown at https://oss.oracle.com/licenses/upl or Apache License 2.0 as shown at http://www.apache.org/licenses/LICENSE-2.0. You may choose either license. 4 5 6from oci.util import formatted_flat_dict, NONE_SENTINEL, value_allowed_none_or_none_sentinel # noqa: F401 7from oci.decorators import init_model_state_from_kwargs 8 9 10@init_model_state_from_kwargs 11class ProblemHistorySummary(object): 12 """ 13 Problem History Definition. 14 """ 15 16 #: A constant which can be used with the actor_type property of a ProblemHistorySummary. 17 #: This constant has a value of "CLOUD_GUARD_SERVICE" 18 ACTOR_TYPE_CLOUD_GUARD_SERVICE = "CLOUD_GUARD_SERVICE" 19 20 #: A constant which can be used with the actor_type property of a ProblemHistorySummary. 21 #: This constant has a value of "CORRELATION" 22 ACTOR_TYPE_CORRELATION = "CORRELATION" 23 24 #: A constant which can be used with the actor_type property of a ProblemHistorySummary. 25 #: This constant has a value of "RESPONDER" 26 ACTOR_TYPE_RESPONDER = "RESPONDER" 27 28 #: A constant which can be used with the actor_type property of a ProblemHistorySummary. 29 #: This constant has a value of "USER" 30 ACTOR_TYPE_USER = "USER" 31 32 #: A constant which can be used with the lifecycle_detail property of a ProblemHistorySummary. 33 #: This constant has a value of "OPEN" 34 LIFECYCLE_DETAIL_OPEN = "OPEN" 35 36 #: A constant which can be used with the lifecycle_detail property of a ProblemHistorySummary. 37 #: This constant has a value of "RESOLVED" 38 LIFECYCLE_DETAIL_RESOLVED = "RESOLVED" 39 40 #: A constant which can be used with the lifecycle_detail property of a ProblemHistorySummary. 41 #: This constant has a value of "DISMISSED" 42 LIFECYCLE_DETAIL_DISMISSED = "DISMISSED" 43 44 #: A constant which can be used with the lifecycle_detail property of a ProblemHistorySummary. 45 #: This constant has a value of "DELETED" 46 LIFECYCLE_DETAIL_DELETED = "DELETED" 47 48 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 49 #: This constant has a value of "REOPEN" 50 EVENT_STATUS_REOPEN = "REOPEN" 51 52 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 53 #: This constant has a value of "OPEN" 54 EVENT_STATUS_OPEN = "OPEN" 55 56 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 57 #: This constant has a value of "UPDATE" 58 EVENT_STATUS_UPDATE = "UPDATE" 59 60 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 61 #: This constant has a value of "RESOLVE" 62 EVENT_STATUS_RESOLVE = "RESOLVE" 63 64 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 65 #: This constant has a value of "DISMISS" 66 EVENT_STATUS_DISMISS = "DISMISS" 67 68 #: A constant which can be used with the event_status property of a ProblemHistorySummary. 69 #: This constant has a value of "DELETE" 70 EVENT_STATUS_DELETE = "DELETE" 71 72 def __init__(self, **kwargs): 73 """ 74 Initializes a new ProblemHistorySummary object with values from keyword arguments. 75 The following keyword arguments are supported (corresponding to the getters/setters of this class): 76 77 :param id: 78 The value to assign to the id property of this ProblemHistorySummary. 79 :type id: str 80 81 :param problem_id: 82 The value to assign to the problem_id property of this ProblemHistorySummary. 83 :type problem_id: str 84 85 :param actor_type: 86 The value to assign to the actor_type property of this ProblemHistorySummary. 87 Allowed values for this property are: "CLOUD_GUARD_SERVICE", "CORRELATION", "RESPONDER", "USER", 'UNKNOWN_ENUM_VALUE'. 88 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 89 :type actor_type: str 90 91 :param actor_name: 92 The value to assign to the actor_name property of this ProblemHistorySummary. 93 :type actor_name: str 94 95 :param explanation: 96 The value to assign to the explanation property of this ProblemHistorySummary. 97 :type explanation: str 98 99 :param lifecycle_detail: 100 The value to assign to the lifecycle_detail property of this ProblemHistorySummary. 101 Allowed values for this property are: "OPEN", "RESOLVED", "DISMISSED", "DELETED", 'UNKNOWN_ENUM_VALUE'. 102 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 103 :type lifecycle_detail: str 104 105 :param event_status: 106 The value to assign to the event_status property of this ProblemHistorySummary. 107 Allowed values for this property are: "REOPEN", "OPEN", "UPDATE", "RESOLVE", "DISMISS", "DELETE", 'UNKNOWN_ENUM_VALUE'. 108 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 109 :type event_status: str 110 111 :param time_created: 112 The value to assign to the time_created property of this ProblemHistorySummary. 113 :type time_created: datetime 114 115 :param delta: 116 The value to assign to the delta property of this ProblemHistorySummary. 117 :type delta: str 118 119 :param comment: 120 The value to assign to the comment property of this ProblemHistorySummary. 121 :type comment: str 122 123 """ 124 self.swagger_types = { 125 'id': 'str', 126 'problem_id': 'str', 127 'actor_type': 'str', 128 'actor_name': 'str', 129 'explanation': 'str', 130 'lifecycle_detail': 'str', 131 'event_status': 'str', 132 'time_created': 'datetime', 133 'delta': 'str', 134 'comment': 'str' 135 } 136 137 self.attribute_map = { 138 'id': 'id', 139 'problem_id': 'problemId', 140 'actor_type': 'actorType', 141 'actor_name': 'actorName', 142 'explanation': 'explanation', 143 'lifecycle_detail': 'lifecycleDetail', 144 'event_status': 'eventStatus', 145 'time_created': 'timeCreated', 146 'delta': 'delta', 147 'comment': 'comment' 148 } 149 150 self._id = None 151 self._problem_id = None 152 self._actor_type = None 153 self._actor_name = None 154 self._explanation = None 155 self._lifecycle_detail = None 156 self._event_status = None 157 self._time_created = None 158 self._delta = None 159 self._comment = None 160 161 @property 162 def id(self): 163 """ 164 **[Required]** Gets the id of this ProblemHistorySummary. 165 Unique identifier for the history record 166 167 168 :return: The id of this ProblemHistorySummary. 169 :rtype: str 170 """ 171 return self._id 172 173 @id.setter 174 def id(self, id): 175 """ 176 Sets the id of this ProblemHistorySummary. 177 Unique identifier for the history record 178 179 180 :param id: The id of this ProblemHistorySummary. 181 :type: str 182 """ 183 self._id = id 184 185 @property 186 def problem_id(self): 187 """ 188 **[Required]** Gets the problem_id of this ProblemHistorySummary. 189 problemId for which history is associated to. 190 191 192 :return: The problem_id of this ProblemHistorySummary. 193 :rtype: str 194 """ 195 return self._problem_id 196 197 @problem_id.setter 198 def problem_id(self, problem_id): 199 """ 200 Sets the problem_id of this ProblemHistorySummary. 201 problemId for which history is associated to. 202 203 204 :param problem_id: The problem_id of this ProblemHistorySummary. 205 :type: str 206 """ 207 self._problem_id = problem_id 208 209 @property 210 def actor_type(self): 211 """ 212 **[Required]** Gets the actor_type of this ProblemHistorySummary. 213 Actor type who performed the operation 214 215 Allowed values for this property are: "CLOUD_GUARD_SERVICE", "CORRELATION", "RESPONDER", "USER", 'UNKNOWN_ENUM_VALUE'. 216 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 217 218 219 :return: The actor_type of this ProblemHistorySummary. 220 :rtype: str 221 """ 222 return self._actor_type 223 224 @actor_type.setter 225 def actor_type(self, actor_type): 226 """ 227 Sets the actor_type of this ProblemHistorySummary. 228 Actor type who performed the operation 229 230 231 :param actor_type: The actor_type of this ProblemHistorySummary. 232 :type: str 233 """ 234 allowed_values = ["CLOUD_GUARD_SERVICE", "CORRELATION", "RESPONDER", "USER"] 235 if not value_allowed_none_or_none_sentinel(actor_type, allowed_values): 236 actor_type = 'UNKNOWN_ENUM_VALUE' 237 self._actor_type = actor_type 238 239 @property 240 def actor_name(self): 241 """ 242 **[Required]** Gets the actor_name of this ProblemHistorySummary. 243 Resource Name who performed activity 244 245 246 :return: The actor_name of this ProblemHistorySummary. 247 :rtype: str 248 """ 249 return self._actor_name 250 251 @actor_name.setter 252 def actor_name(self, actor_name): 253 """ 254 Sets the actor_name of this ProblemHistorySummary. 255 Resource Name who performed activity 256 257 258 :param actor_name: The actor_name of this ProblemHistorySummary. 259 :type: str 260 """ 261 self._actor_name = actor_name 262 263 @property 264 def explanation(self): 265 """ 266 **[Required]** Gets the explanation of this ProblemHistorySummary. 267 Activity explanation details 268 269 270 :return: The explanation of this ProblemHistorySummary. 271 :rtype: str 272 """ 273 return self._explanation 274 275 @explanation.setter 276 def explanation(self, explanation): 277 """ 278 Sets the explanation of this ProblemHistorySummary. 279 Activity explanation details 280 281 282 :param explanation: The explanation of this ProblemHistorySummary. 283 :type: str 284 """ 285 self._explanation = explanation 286 287 @property 288 def lifecycle_detail(self): 289 """ 290 **[Required]** Gets the lifecycle_detail of this ProblemHistorySummary. 291 Problem Lifecycle Detail Status 292 293 Allowed values for this property are: "OPEN", "RESOLVED", "DISMISSED", "DELETED", 'UNKNOWN_ENUM_VALUE'. 294 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 295 296 297 :return: The lifecycle_detail of this ProblemHistorySummary. 298 :rtype: str 299 """ 300 return self._lifecycle_detail 301 302 @lifecycle_detail.setter 303 def lifecycle_detail(self, lifecycle_detail): 304 """ 305 Sets the lifecycle_detail of this ProblemHistorySummary. 306 Problem Lifecycle Detail Status 307 308 309 :param lifecycle_detail: The lifecycle_detail of this ProblemHistorySummary. 310 :type: str 311 """ 312 allowed_values = ["OPEN", "RESOLVED", "DISMISSED", "DELETED"] 313 if not value_allowed_none_or_none_sentinel(lifecycle_detail, allowed_values): 314 lifecycle_detail = 'UNKNOWN_ENUM_VALUE' 315 self._lifecycle_detail = lifecycle_detail 316 317 @property 318 def event_status(self): 319 """ 320 Gets the event_status of this ProblemHistorySummary. 321 Event status 322 323 Allowed values for this property are: "REOPEN", "OPEN", "UPDATE", "RESOLVE", "DISMISS", "DELETE", 'UNKNOWN_ENUM_VALUE'. 324 Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. 325 326 327 :return: The event_status of this ProblemHistorySummary. 328 :rtype: str 329 """ 330 return self._event_status 331 332 @event_status.setter 333 def event_status(self, event_status): 334 """ 335 Sets the event_status of this ProblemHistorySummary. 336 Event status 337 338 339 :param event_status: The event_status of this ProblemHistorySummary. 340 :type: str 341 """ 342 allowed_values = ["REOPEN", "OPEN", "UPDATE", "RESOLVE", "DISMISS", "DELETE"] 343 if not value_allowed_none_or_none_sentinel(event_status, allowed_values): 344 event_status = 'UNKNOWN_ENUM_VALUE' 345 self._event_status = event_status 346 347 @property 348 def time_created(self): 349 """ 350 **[Required]** Gets the time_created of this ProblemHistorySummary. 351 Type of the Entity 352 353 354 :return: The time_created of this ProblemHistorySummary. 355 :rtype: datetime 356 """ 357 return self._time_created 358 359 @time_created.setter 360 def time_created(self, time_created): 361 """ 362 Sets the time_created of this ProblemHistorySummary. 363 Type of the Entity 364 365 366 :param time_created: The time_created of this ProblemHistorySummary. 367 :type: datetime 368 """ 369 self._time_created = time_created 370 371 @property 372 def delta(self): 373 """ 374 **[Required]** Gets the delta of this ProblemHistorySummary. 375 Impacted Resource Names in a comma-separated string. 376 377 378 :return: The delta of this ProblemHistorySummary. 379 :rtype: str 380 """ 381 return self._delta 382 383 @delta.setter 384 def delta(self, delta): 385 """ 386 Sets the delta of this ProblemHistorySummary. 387 Impacted Resource Names in a comma-separated string. 388 389 390 :param delta: The delta of this ProblemHistorySummary. 391 :type: str 392 """ 393 self._delta = delta 394 395 @property 396 def comment(self): 397 """ 398 Gets the comment of this ProblemHistorySummary. 399 User Defined Comments 400 401 402 :return: The comment of this ProblemHistorySummary. 403 :rtype: str 404 """ 405 return self._comment 406 407 @comment.setter 408 def comment(self, comment): 409 """ 410 Sets the comment of this ProblemHistorySummary. 411 User Defined Comments 412 413 414 :param comment: The comment of this ProblemHistorySummary. 415 :type: str 416 """ 417 self._comment = comment 418 419 def __repr__(self): 420 return formatted_flat_dict(self) 421 422 def __eq__(self, other): 423 if other is None: 424 return False 425 426 return self.__dict__ == other.__dict__ 427 428 def __ne__(self, other): 429 return not self == other 430