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 BuildRunSummary(object): 12 """ 13 Summary of the build run. 14 """ 15 16 def __init__(self, **kwargs): 17 """ 18 Initializes a new BuildRunSummary object with values from keyword arguments. 19 The following keyword arguments are supported (corresponding to the getters/setters of this class): 20 21 :param id: 22 The value to assign to the id property of this BuildRunSummary. 23 :type id: str 24 25 :param compartment_id: 26 The value to assign to the compartment_id property of this BuildRunSummary. 27 :type compartment_id: str 28 29 :param display_name: 30 The value to assign to the display_name property of this BuildRunSummary. 31 :type display_name: str 32 33 :param project_id: 34 The value to assign to the project_id property of this BuildRunSummary. 35 :type project_id: str 36 37 :param build_pipeline_id: 38 The value to assign to the build_pipeline_id property of this BuildRunSummary. 39 :type build_pipeline_id: str 40 41 :param build_run_source: 42 The value to assign to the build_run_source property of this BuildRunSummary. 43 :type build_run_source: oci.devops.models.BuildRunSource 44 45 :param build_run_arguments: 46 The value to assign to the build_run_arguments property of this BuildRunSummary. 47 :type build_run_arguments: oci.devops.models.BuildRunArgumentCollection 48 49 :param build_run_progress_summary: 50 The value to assign to the build_run_progress_summary property of this BuildRunSummary. 51 :type build_run_progress_summary: oci.devops.models.BuildRunProgressSummary 52 53 :param time_created: 54 The value to assign to the time_created property of this BuildRunSummary. 55 :type time_created: datetime 56 57 :param time_updated: 58 The value to assign to the time_updated property of this BuildRunSummary. 59 :type time_updated: datetime 60 61 :param lifecycle_state: 62 The value to assign to the lifecycle_state property of this BuildRunSummary. 63 :type lifecycle_state: str 64 65 :param lifecycle_details: 66 The value to assign to the lifecycle_details property of this BuildRunSummary. 67 :type lifecycle_details: str 68 69 :param commit_info: 70 The value to assign to the commit_info property of this BuildRunSummary. 71 :type commit_info: oci.devops.models.CommitInfo 72 73 :param freeform_tags: 74 The value to assign to the freeform_tags property of this BuildRunSummary. 75 :type freeform_tags: dict(str, str) 76 77 :param defined_tags: 78 The value to assign to the defined_tags property of this BuildRunSummary. 79 :type defined_tags: dict(str, dict(str, object)) 80 81 :param system_tags: 82 The value to assign to the system_tags property of this BuildRunSummary. 83 :type system_tags: dict(str, dict(str, object)) 84 85 """ 86 self.swagger_types = { 87 'id': 'str', 88 'compartment_id': 'str', 89 'display_name': 'str', 90 'project_id': 'str', 91 'build_pipeline_id': 'str', 92 'build_run_source': 'BuildRunSource', 93 'build_run_arguments': 'BuildRunArgumentCollection', 94 'build_run_progress_summary': 'BuildRunProgressSummary', 95 'time_created': 'datetime', 96 'time_updated': 'datetime', 97 'lifecycle_state': 'str', 98 'lifecycle_details': 'str', 99 'commit_info': 'CommitInfo', 100 'freeform_tags': 'dict(str, str)', 101 'defined_tags': 'dict(str, dict(str, object))', 102 'system_tags': 'dict(str, dict(str, object))' 103 } 104 105 self.attribute_map = { 106 'id': 'id', 107 'compartment_id': 'compartmentId', 108 'display_name': 'displayName', 109 'project_id': 'projectId', 110 'build_pipeline_id': 'buildPipelineId', 111 'build_run_source': 'buildRunSource', 112 'build_run_arguments': 'buildRunArguments', 113 'build_run_progress_summary': 'buildRunProgressSummary', 114 'time_created': 'timeCreated', 115 'time_updated': 'timeUpdated', 116 'lifecycle_state': 'lifecycleState', 117 'lifecycle_details': 'lifecycleDetails', 118 'commit_info': 'commitInfo', 119 'freeform_tags': 'freeformTags', 120 'defined_tags': 'definedTags', 121 'system_tags': 'systemTags' 122 } 123 124 self._id = None 125 self._compartment_id = None 126 self._display_name = None 127 self._project_id = None 128 self._build_pipeline_id = None 129 self._build_run_source = None 130 self._build_run_arguments = None 131 self._build_run_progress_summary = None 132 self._time_created = None 133 self._time_updated = None 134 self._lifecycle_state = None 135 self._lifecycle_details = None 136 self._commit_info = None 137 self._freeform_tags = None 138 self._defined_tags = None 139 self._system_tags = None 140 141 @property 142 def id(self): 143 """ 144 **[Required]** Gets the id of this BuildRunSummary. 145 Unique identifier that is immutable on creation. 146 147 148 :return: The id of this BuildRunSummary. 149 :rtype: str 150 """ 151 return self._id 152 153 @id.setter 154 def id(self, id): 155 """ 156 Sets the id of this BuildRunSummary. 157 Unique identifier that is immutable on creation. 158 159 160 :param id: The id of this BuildRunSummary. 161 :type: str 162 """ 163 self._id = id 164 165 @property 166 def compartment_id(self): 167 """ 168 **[Required]** Gets the compartment_id of this BuildRunSummary. 169 The OCID of the compartment where the build is running. 170 171 172 :return: The compartment_id of this BuildRunSummary. 173 :rtype: str 174 """ 175 return self._compartment_id 176 177 @compartment_id.setter 178 def compartment_id(self, compartment_id): 179 """ 180 Sets the compartment_id of this BuildRunSummary. 181 The OCID of the compartment where the build is running. 182 183 184 :param compartment_id: The compartment_id of this BuildRunSummary. 185 :type: str 186 """ 187 self._compartment_id = compartment_id 188 189 @property 190 def display_name(self): 191 """ 192 Gets the display_name of this BuildRunSummary. 193 Build run display name, which can be renamed and is not necessarily unique. Avoid entering confidential information. 194 195 196 :return: The display_name of this BuildRunSummary. 197 :rtype: str 198 """ 199 return self._display_name 200 201 @display_name.setter 202 def display_name(self, display_name): 203 """ 204 Sets the display_name of this BuildRunSummary. 205 Build run display name, which can be renamed and is not necessarily unique. Avoid entering confidential information. 206 207 208 :param display_name: The display_name of this BuildRunSummary. 209 :type: str 210 """ 211 self._display_name = display_name 212 213 @property 214 def project_id(self): 215 """ 216 **[Required]** Gets the project_id of this BuildRunSummary. 217 The OCID of the DevOps project. 218 219 220 :return: The project_id of this BuildRunSummary. 221 :rtype: str 222 """ 223 return self._project_id 224 225 @project_id.setter 226 def project_id(self, project_id): 227 """ 228 Sets the project_id of this BuildRunSummary. 229 The OCID of the DevOps project. 230 231 232 :param project_id: The project_id of this BuildRunSummary. 233 :type: str 234 """ 235 self._project_id = project_id 236 237 @property 238 def build_pipeline_id(self): 239 """ 240 **[Required]** Gets the build_pipeline_id of this BuildRunSummary. 241 The OCID of the build pipeline. 242 243 244 :return: The build_pipeline_id of this BuildRunSummary. 245 :rtype: str 246 """ 247 return self._build_pipeline_id 248 249 @build_pipeline_id.setter 250 def build_pipeline_id(self, build_pipeline_id): 251 """ 252 Sets the build_pipeline_id of this BuildRunSummary. 253 The OCID of the build pipeline. 254 255 256 :param build_pipeline_id: The build_pipeline_id of this BuildRunSummary. 257 :type: str 258 """ 259 self._build_pipeline_id = build_pipeline_id 260 261 @property 262 def build_run_source(self): 263 """ 264 **[Required]** Gets the build_run_source of this BuildRunSummary. 265 266 :return: The build_run_source of this BuildRunSummary. 267 :rtype: oci.devops.models.BuildRunSource 268 """ 269 return self._build_run_source 270 271 @build_run_source.setter 272 def build_run_source(self, build_run_source): 273 """ 274 Sets the build_run_source of this BuildRunSummary. 275 276 :param build_run_source: The build_run_source of this BuildRunSummary. 277 :type: oci.devops.models.BuildRunSource 278 """ 279 self._build_run_source = build_run_source 280 281 @property 282 def build_run_arguments(self): 283 """ 284 Gets the build_run_arguments of this BuildRunSummary. 285 286 :return: The build_run_arguments of this BuildRunSummary. 287 :rtype: oci.devops.models.BuildRunArgumentCollection 288 """ 289 return self._build_run_arguments 290 291 @build_run_arguments.setter 292 def build_run_arguments(self, build_run_arguments): 293 """ 294 Sets the build_run_arguments of this BuildRunSummary. 295 296 :param build_run_arguments: The build_run_arguments of this BuildRunSummary. 297 :type: oci.devops.models.BuildRunArgumentCollection 298 """ 299 self._build_run_arguments = build_run_arguments 300 301 @property 302 def build_run_progress_summary(self): 303 """ 304 Gets the build_run_progress_summary of this BuildRunSummary. 305 306 :return: The build_run_progress_summary of this BuildRunSummary. 307 :rtype: oci.devops.models.BuildRunProgressSummary 308 """ 309 return self._build_run_progress_summary 310 311 @build_run_progress_summary.setter 312 def build_run_progress_summary(self, build_run_progress_summary): 313 """ 314 Sets the build_run_progress_summary of this BuildRunSummary. 315 316 :param build_run_progress_summary: The build_run_progress_summary of this BuildRunSummary. 317 :type: oci.devops.models.BuildRunProgressSummary 318 """ 319 self._build_run_progress_summary = build_run_progress_summary 320 321 @property 322 def time_created(self): 323 """ 324 Gets the time_created of this BuildRunSummary. 325 The time the build run was created. Format defined by `RFC3339`__. 326 327 __ https://datatracker.ietf.org/doc/html/rfc3339 328 329 330 :return: The time_created of this BuildRunSummary. 331 :rtype: datetime 332 """ 333 return self._time_created 334 335 @time_created.setter 336 def time_created(self, time_created): 337 """ 338 Sets the time_created of this BuildRunSummary. 339 The time the build run was created. Format defined by `RFC3339`__. 340 341 __ https://datatracker.ietf.org/doc/html/rfc3339 342 343 344 :param time_created: The time_created of this BuildRunSummary. 345 :type: datetime 346 """ 347 self._time_created = time_created 348 349 @property 350 def time_updated(self): 351 """ 352 Gets the time_updated of this BuildRunSummary. 353 The time the build run was updated. Format defined by `RFC3339`__. 354 355 __ https://datatracker.ietf.org/doc/html/rfc3339 356 357 358 :return: The time_updated of this BuildRunSummary. 359 :rtype: datetime 360 """ 361 return self._time_updated 362 363 @time_updated.setter 364 def time_updated(self, time_updated): 365 """ 366 Sets the time_updated of this BuildRunSummary. 367 The time the build run was updated. Format defined by `RFC3339`__. 368 369 __ https://datatracker.ietf.org/doc/html/rfc3339 370 371 372 :param time_updated: The time_updated of this BuildRunSummary. 373 :type: datetime 374 """ 375 self._time_updated = time_updated 376 377 @property 378 def lifecycle_state(self): 379 """ 380 Gets the lifecycle_state of this BuildRunSummary. 381 The current state of the build run. 382 383 384 :return: The lifecycle_state of this BuildRunSummary. 385 :rtype: str 386 """ 387 return self._lifecycle_state 388 389 @lifecycle_state.setter 390 def lifecycle_state(self, lifecycle_state): 391 """ 392 Sets the lifecycle_state of this BuildRunSummary. 393 The current state of the build run. 394 395 396 :param lifecycle_state: The lifecycle_state of this BuildRunSummary. 397 :type: str 398 """ 399 self._lifecycle_state = lifecycle_state 400 401 @property 402 def lifecycle_details(self): 403 """ 404 Gets the lifecycle_details of this BuildRunSummary. 405 A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state. 406 407 408 :return: The lifecycle_details of this BuildRunSummary. 409 :rtype: str 410 """ 411 return self._lifecycle_details 412 413 @lifecycle_details.setter 414 def lifecycle_details(self, lifecycle_details): 415 """ 416 Sets the lifecycle_details of this BuildRunSummary. 417 A message describing the current state in more detail. For example, can be used to provide actionable information for a resource in Failed state. 418 419 420 :param lifecycle_details: The lifecycle_details of this BuildRunSummary. 421 :type: str 422 """ 423 self._lifecycle_details = lifecycle_details 424 425 @property 426 def commit_info(self): 427 """ 428 Gets the commit_info of this BuildRunSummary. 429 430 :return: The commit_info of this BuildRunSummary. 431 :rtype: oci.devops.models.CommitInfo 432 """ 433 return self._commit_info 434 435 @commit_info.setter 436 def commit_info(self, commit_info): 437 """ 438 Sets the commit_info of this BuildRunSummary. 439 440 :param commit_info: The commit_info of this BuildRunSummary. 441 :type: oci.devops.models.CommitInfo 442 """ 443 self._commit_info = commit_info 444 445 @property 446 def freeform_tags(self): 447 """ 448 Gets the freeform_tags of this BuildRunSummary. 449 Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` 450 451 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 452 453 454 :return: The freeform_tags of this BuildRunSummary. 455 :rtype: dict(str, str) 456 """ 457 return self._freeform_tags 458 459 @freeform_tags.setter 460 def freeform_tags(self, freeform_tags): 461 """ 462 Sets the freeform_tags of this BuildRunSummary. 463 Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. See `Resource Tags`__. Example: `{\"bar-key\": \"value\"}` 464 465 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 466 467 468 :param freeform_tags: The freeform_tags of this BuildRunSummary. 469 :type: dict(str, str) 470 """ 471 self._freeform_tags = freeform_tags 472 473 @property 474 def defined_tags(self): 475 """ 476 Gets the defined_tags of this BuildRunSummary. 477 Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` 478 479 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 480 481 482 :return: The defined_tags of this BuildRunSummary. 483 :rtype: dict(str, dict(str, object)) 484 """ 485 return self._defined_tags 486 487 @defined_tags.setter 488 def defined_tags(self, defined_tags): 489 """ 490 Sets the defined_tags of this BuildRunSummary. 491 Defined tags for this resource. Each key is predefined and scoped to a namespace. See `Resource Tags`__. Example: `{\"foo-namespace\": {\"bar-key\": \"value\"}}` 492 493 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 494 495 496 :param defined_tags: The defined_tags of this BuildRunSummary. 497 :type: dict(str, dict(str, object)) 498 """ 499 self._defined_tags = defined_tags 500 501 @property 502 def system_tags(self): 503 """ 504 Gets the system_tags of this BuildRunSummary. 505 Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` 506 507 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 508 509 510 :return: The system_tags of this BuildRunSummary. 511 :rtype: dict(str, dict(str, object)) 512 """ 513 return self._system_tags 514 515 @system_tags.setter 516 def system_tags(self, system_tags): 517 """ 518 Sets the system_tags of this BuildRunSummary. 519 Usage of system tag keys. These predefined keys are scoped to namespaces. See `Resource Tags`__. Example: `{\"orcl-cloud\": {\"free-tier-retained\": \"true\"}}` 520 521 __ https://docs.cloud.oracle.com/Content/General/Concepts/resourcetags.htm 522 523 524 :param system_tags: The system_tags of this BuildRunSummary. 525 :type: dict(str, dict(str, object)) 526 """ 527 self._system_tags = system_tags 528 529 def __repr__(self): 530 return formatted_flat_dict(self) 531 532 def __eq__(self, other): 533 if other is None: 534 return False 535 536 return self.__dict__ == other.__dict__ 537 538 def __ne__(self, other): 539 return not self == other 540