ResourceFilters¶
-
class
oci.opsi.models.
ResourceFilters
(**kwargs)¶ Bases:
object
Information to filter the actual target resources in an operation. e.g: While querying a DATABASE_INSIGHTS_DATA_OBJECT using /opsiDataObjects/actions/queryData API, if resourceFilters is set with valid value for definedTagEquals field, only data of the database insights resources for which the specified freeform tags exist will be considered for the actual query scope.
Attributes
RESOURCE_STATUS_DISABLED
A constant which can be used with the resource_status property of a ResourceFilters. RESOURCE_STATUS_ENABLED
A constant which can be used with the resource_status property of a ResourceFilters. RESOURCE_STATUS_TERMINATED
A constant which can be used with the resource_status property of a ResourceFilters. compartment_id_in_subtree
Gets the compartment_id_in_subtree of this ResourceFilters. defined_tag_equals
Gets the defined_tag_equals of this ResourceFilters. defined_tag_exists
Gets the defined_tag_exists of this ResourceFilters. freeform_tag_equals
Gets the freeform_tag_equals of this ResourceFilters. freeform_tag_exists
Gets the freeform_tag_exists of this ResourceFilters. resource_status
Gets the resource_status of this ResourceFilters. Methods
__init__
(**kwargs)Initializes a new ResourceFilters object with values from keyword arguments. -
RESOURCE_STATUS_DISABLED
= 'DISABLED'¶ A constant which can be used with the resource_status property of a ResourceFilters. This constant has a value of “DISABLED”
-
RESOURCE_STATUS_ENABLED
= 'ENABLED'¶ A constant which can be used with the resource_status property of a ResourceFilters. This constant has a value of “ENABLED”
-
RESOURCE_STATUS_TERMINATED
= 'TERMINATED'¶ A constant which can be used with the resource_status property of a ResourceFilters. This constant has a value of “TERMINATED”
-
__init__
(**kwargs)¶ Initializes a new ResourceFilters object with values from keyword arguments. The following keyword arguments are supported (corresponding to the getters/setters of this class):
Parameters: - defined_tag_equals (list[str]) – The value to assign to the defined_tag_equals property of this ResourceFilters.
- freeform_tag_equals (list[str]) – The value to assign to the freeform_tag_equals property of this ResourceFilters.
- defined_tag_exists (list[str]) – The value to assign to the defined_tag_exists property of this ResourceFilters.
- freeform_tag_exists (list[str]) – The value to assign to the freeform_tag_exists property of this ResourceFilters.
- compartment_id_in_subtree (bool) – The value to assign to the compartment_id_in_subtree property of this ResourceFilters.
- resource_status (list[str]) – The value to assign to the resource_status property of this ResourceFilters. Allowed values for items in this list are: “DISABLED”, “ENABLED”, “TERMINATED”
-
compartment_id_in_subtree
¶ Gets the compartment_id_in_subtree of this ResourceFilters. A flag to consider all resources within a given compartment and all sub-compartments.
Returns: The compartment_id_in_subtree of this ResourceFilters. Return type: bool
-
defined_tag_equals
¶ Gets the defined_tag_equals of this ResourceFilters. A list of tag filters to apply. Only resources with a defined tag matching the value will be considered. Each item in the list has the format “{namespace}.{tagName}.{value}”. All inputs are case-insensitive. Multiple values for the same key (i.e. same namespace and tag name) are interpreted as “OR”. Values for different keys (i.e. different namespaces, different tag names, or both) are interpreted as “AND”.
Returns: The defined_tag_equals of this ResourceFilters. Return type: list[str]
-
defined_tag_exists
¶ Gets the defined_tag_exists of this ResourceFilters. A list of tag existence filters to apply. Only resources for which the specified defined tags exist will be considered. Each item in the list has the format “{namespace}.{tagName}.true” (for checking existence of a defined tag) or “{namespace}.true”. All inputs are case-insensitive. Currently, only existence (“true” at the end) is supported. Absence (“false” at the end) is not supported. Multiple values for the same key (i.e. same namespace and tag name) are interpreted as “OR”. Values for different keys (i.e. different namespaces, different tag names, or both) are interpreted as “AND”.
Returns: The defined_tag_exists of this ResourceFilters. Return type: list[str]
-
freeform_tag_equals
¶ Gets the freeform_tag_equals of this ResourceFilters. A list of tag filters to apply. Only resources with a freeform tag matching the value will be considered. The key for each tag is “{tagName}.{value}”. All inputs are case-insensitive. Multiple values for the same tag name are interpreted as “OR”. Values for different tag names are interpreted as “AND”.
Returns: The freeform_tag_equals of this ResourceFilters. Return type: list[str]
-
freeform_tag_exists
¶ Gets the freeform_tag_exists of this ResourceFilters. A list of tag existence filters to apply. Only resources for which the specified freeform tags exist will be considered. The key for each tag is “{tagName}.true”. All inputs are case-insensitive. Currently, only existence (“true” at the end) is supported. Absence (“false” at the end) is not supported. Multiple values for different tag names are interpreted as “AND”.
Returns: The freeform_tag_exists of this ResourceFilters. Return type: list[str]
-
resource_status
¶ Gets the resource_status of this ResourceFilters. Filter resources by status, multiple options could be chosen to show authorized resources even if those are disabled or deleted.
Allowed values for items in this list are: “DISABLED”, “ENABLED”, “TERMINATED”
Returns: The resource_status of this ResourceFilters. Return type: list[str]
-