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 ConditionGroup(object):
12    """
13    Condition configured on a target
14    """
15
16    def __init__(self, **kwargs):
17        """
18        Initializes a new ConditionGroup object with values from keyword arguments.
19        The following keyword arguments are supported (corresponding to the getters/setters of this class):
20
21        :param compartment_id:
22            The value to assign to the compartment_id property of this ConditionGroup.
23        :type compartment_id: str
24
25        :param condition:
26            The value to assign to the condition property of this ConditionGroup.
27        :type condition: oci.cloud_guard.models.Condition
28
29        """
30        self.swagger_types = {
31            'compartment_id': 'str',
32            'condition': 'Condition'
33        }
34
35        self.attribute_map = {
36            'compartment_id': 'compartmentId',
37            'condition': 'condition'
38        }
39
40        self._compartment_id = None
41        self._condition = None
42
43    @property
44    def compartment_id(self):
45        """
46        **[Required]** Gets the compartment_id of this ConditionGroup.
47        compartment associated with condition
48
49
50        :return: The compartment_id of this ConditionGroup.
51        :rtype: str
52        """
53        return self._compartment_id
54
55    @compartment_id.setter
56    def compartment_id(self, compartment_id):
57        """
58        Sets the compartment_id of this ConditionGroup.
59        compartment associated with condition
60
61
62        :param compartment_id: The compartment_id of this ConditionGroup.
63        :type: str
64        """
65        self._compartment_id = compartment_id
66
67    @property
68    def condition(self):
69        """
70        **[Required]** Gets the condition of this ConditionGroup.
71
72        :return: The condition of this ConditionGroup.
73        :rtype: oci.cloud_guard.models.Condition
74        """
75        return self._condition
76
77    @condition.setter
78    def condition(self, condition):
79        """
80        Sets the condition of this ConditionGroup.
81
82        :param condition: The condition of this ConditionGroup.
83        :type: oci.cloud_guard.models.Condition
84        """
85        self._condition = condition
86
87    def __repr__(self):
88        return formatted_flat_dict(self)
89
90    def __eq__(self, other):
91        if other is None:
92            return False
93
94        return self.__dict__ == other.__dict__
95
96    def __ne__(self, other):
97        return not self == other
98