a fZb@s8ddlmZmZmZddlmZeGdddeZdS))formatted_flat_dict NONE_SENTINEL#value_allowed_none_or_none_sentinel)init_model_state_from_kwargsc@s>eZdZdZdZdZdZdZdZdZ dZ dZ d Z d Z d Zd Zd ZdZdZdZdZdZddZeddZeddZejddZeddZejddZeddZejddZed d!Zejd"d!Zed#d$Zejd%d$Zed&d'Z e jd(d'Z ed)d*Z!e!jd+d*Z!ed,d-Z"e"jd.d-Z"ed/d0Z#e#jd1d0Z#ed2d3Z$e$jd4d3Z$ed5d6Z%e%jd7d6Z%ed8d9Z&e&jd:d9Z&ed;d<Z'e'jd=d<Z'ed>d?Z(e(jd@d?Z(edAdBZ)e)jdCdBZ)edDdEZ*e*jdFdEZ*edGdHZ+e+jdIdHZ+dJdKZ,dLdMZ-dNdOZ.dPS)Q ScheduledTaskz0 Log analytics scheduled task resource. ACCELERATIONSTANDARD SAVED_SEARCHPURGEREADYPAUSED COMPLETEDBLOCKEDMETRIC_EXTRACTION_NOT_VALIDSAVED_SEARCH_NOT_VALIDSAVED_SEARCH_NOT_FOUNDQUERY_STRING_NOT_VALID USER_ACTIONTENANCY_LIFECYCLEPURGE_RESOURCE_NOT_FOUNDACTIVEDELETEDcKsdddddddddddddddddd|_d d d d d ddddddddddddd|_d|_d|_d|_d|_d|_d|_d|_d|_ d|_ d|_ d|_ d|_ d|_d|_d|_d|_d|_dS)a@ Initializes a new ScheduledTask object with values from keyword arguments. This class has the following subclasses and if you are using this class as input to a service operations then you should favor using a subclass over the base class: * :class:`~oci.log_analytics.models.StandardTask` The following keyword arguments are supported (corresponding to the getters/setters of this class): :param kind: The value to assign to the kind property of this ScheduledTask. Allowed values for this property are: "ACCELERATION", "STANDARD", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type kind: str :param id: The value to assign to the id property of this ScheduledTask. :type id: str :param display_name: The value to assign to the display_name property of this ScheduledTask. :type display_name: str :param task_type: The value to assign to the task_type property of this ScheduledTask. Allowed values for this property are: "SAVED_SEARCH", "ACCELERATION", "PURGE", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type task_type: str :param schedules: The value to assign to the schedules property of this ScheduledTask. :type schedules: list[oci.log_analytics.models.Schedule] :param action: The value to assign to the action property of this ScheduledTask. :type action: oci.log_analytics.models.Action :param task_status: The value to assign to the task_status property of this ScheduledTask. Allowed values for this property are: "READY", "PAUSED", "COMPLETED", "BLOCKED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type task_status: str :param pause_reason: The value to assign to the pause_reason property of this ScheduledTask. Allowed values for this property are: "METRIC_EXTRACTION_NOT_VALID", "SAVED_SEARCH_NOT_VALID", "SAVED_SEARCH_NOT_FOUND", "QUERY_STRING_NOT_VALID", "USER_ACTION", "TENANCY_LIFECYCLE", "PURGE_RESOURCE_NOT_FOUND", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type pause_reason: str :param work_request_id: The value to assign to the work_request_id property of this ScheduledTask. :type work_request_id: str :param num_occurrences: The value to assign to the num_occurrences property of this ScheduledTask. :type num_occurrences: int :param compartment_id: The value to assign to the compartment_id property of this ScheduledTask. :type compartment_id: str :param time_created: The value to assign to the time_created property of this ScheduledTask. :type time_created: datetime :param time_updated: The value to assign to the time_updated property of this ScheduledTask. :type time_updated: datetime :param time_of_next_execution: The value to assign to the time_of_next_execution property of this ScheduledTask. :type time_of_next_execution: datetime :param lifecycle_state: The value to assign to the lifecycle_state property of this ScheduledTask. Allowed values for this property are: "ACTIVE", "DELETED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :type lifecycle_state: str :param freeform_tags: The value to assign to the freeform_tags property of this ScheduledTask. :type freeform_tags: dict(str, str) :param defined_tags: The value to assign to the defined_tags property of this ScheduledTask. :type defined_tags: dict(str, dict(str, object)) strzlist[Schedule]ActionintZdatetimezdict(str, str)zdict(str, dict(str, object)))kindid display_name task_type schedulesaction task_status pause_reasonwork_request_idnum_occurrencescompartment_id time_created time_updatedtime_of_next_executionlifecycle_state freeform_tags defined_tagsrrZ displayNameZtaskTyperr Z taskStatusZ pauseReasonZ workRequestIdZnumOccurrencesZ compartmentIdZ timeCreatedZ timeUpdatedZtimeOfNextExecutionZlifecycleStateZ freeformTagsZ definedTagsN)Z swagger_typesZ attribute_map_kind_id _display_name _task_type _schedules_action _task_status _pause_reason_work_request_id_num_occurrences_compartment_id _time_created _time_updated_time_of_next_execution_lifecycle_state_freeform_tags _defined_tags)selfkwargsr?K/usr/lib/python3.9/site-packages/oci/log_analytics/models/scheduled_task.py__init__ZsjYzScheduledTask.__init__cCs|d}|dkrdSdSdS)z Given the hash representation of a subtype of this class, use the info in the hash to return the class of the subtype. rrZ StandardTaskrNr?)Zobject_dictionarytyper?r?r@ get_subtypeszScheduledTask.get_subtypecCs|jS)ab **[Required]** Gets the kind of this ScheduledTask. Discriminator. Allowed values for this property are: "ACCELERATION", "STANDARD", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :return: The kind of this ScheduledTask. :rtype: str )r,r=r?r?r@rs zScheduledTask.kindcCs ddg}t||sd}||_dS)z Sets the kind of this ScheduledTask. Discriminator. :param kind: The kind of this ScheduledTask. :type: str rrUNKNOWN_ENUM_VALUEN)rr,)r=rallowed_valuesr?r?r@rs  cCs|jS)a **[Required]** Gets the id of this ScheduledTask. The `OCID`__ of the data plane resource. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :return: The id of this ScheduledTask. :rtype: str r-rDr?r?r@rs zScheduledTask.idcCs ||_dS)a Sets the id of this ScheduledTask. The `OCID`__ of the data plane resource. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param id: The id of this ScheduledTask. :type: str NrG)r=rr?r?r@r%s cCs|jS)a **[Required]** Gets the display_name of this ScheduledTask. A user-friendly name that is changeable and that does not have to be unique. Format: a leading alphanumeric, followed by zero or more alphanumerics, underscores, spaces, backslashes, or hyphens in any order). No trailing spaces allowed. :return: The display_name of this ScheduledTask. :rtype: str r.rDr?r?r@r3s zScheduledTask.display_namecCs ||_dS)a Sets the display_name of this ScheduledTask. A user-friendly name that is changeable and that does not have to be unique. Format: a leading alphanumeric, followed by zero or more alphanumerics, underscores, spaces, backslashes, or hyphens in any order). No trailing spaces allowed. :param display_name: The display_name of this ScheduledTask. :type: str NrH)r=rr?r?r@rBs cCs|jS)au **[Required]** Gets the task_type of this ScheduledTask. Task type. Allowed values for this property are: "SAVED_SEARCH", "ACCELERATION", "PURGE", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :return: The task_type of this ScheduledTask. :rtype: str )r/rDr?r?r@rQs zScheduledTask.task_typecCs gd}t||sd}||_dS)z Sets the task_type of this ScheduledTask. Task type. :param task_type: The task_type of this ScheduledTask. :type: str )r rr rEN)rr/)r=rrFr?r?r@r`s  cCs|jS)z **[Required]** Gets the schedules of this ScheduledTask. Schedules. :return: The schedules of this ScheduledTask. :rtype: list[oci.log_analytics.models.Schedule] r0rDr?r?r@ros zScheduledTask.schedulescCs ||_dS)z Sets the schedules of this ScheduledTask. Schedules. :param schedules: The schedules of this ScheduledTask. :type: list[oci.log_analytics.models.Schedule] NrI)r=rr?r?r@r{s cCs|jS)z **[Required]** Gets the action of this ScheduledTask. :return: The action of this ScheduledTask. :rtype: oci.log_analytics.models.Action r1rDr?r?r@r szScheduledTask.actioncCs ||_dS)z Sets the action of this ScheduledTask. :param action: The action of this ScheduledTask. :type: oci.log_analytics.models.Action NrJ)r=r r?r?r@r scCs|jS)a Gets the task_status of this ScheduledTask. Status of the scheduled task. Allowed values for this property are: "READY", "PAUSED", "COMPLETED", "BLOCKED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :return: The task_status of this ScheduledTask. :rtype: str )r2rDr?r?r@r!s zScheduledTask.task_statuscCs gd}t||sd}||_dS)z Sets the task_status of this ScheduledTask. Status of the scheduled task. :param task_status: The task_status of this ScheduledTask. :type: str )r r r rrEN)rr2)r=r!rFr?r?r@r!s  cCs|jS)a Gets the pause_reason of this ScheduledTask. reason for taskStatus PAUSED. Allowed values for this property are: "METRIC_EXTRACTION_NOT_VALID", "SAVED_SEARCH_NOT_VALID", "SAVED_SEARCH_NOT_FOUND", "QUERY_STRING_NOT_VALID", "USER_ACTION", "TENANCY_LIFECYCLE", "PURGE_RESOURCE_NOT_FOUND", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :return: The pause_reason of this ScheduledTask. :rtype: str )r3rDr?r?r@r"s zScheduledTask.pause_reasoncCs gd}t||sd}||_dS)z Sets the pause_reason of this ScheduledTask. reason for taskStatus PAUSED. :param pause_reason: The pause_reason of this ScheduledTask. :type: str )rrrrrrrrEN)rr3)r=r"rFr?r?r@r"s  cCs|jS)a? Gets the work_request_id of this ScheduledTask. most recent Work Request Identifier `OCID]`__ for the asynchronous request. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :return: The work_request_id of this ScheduledTask. :rtype: str r4rDr?r?r@r#s zScheduledTask.work_request_idcCs ||_dS)aM Sets the work_request_id of this ScheduledTask. most recent Work Request Identifier `OCID]`__ for the asynchronous request. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param work_request_id: The work_request_id of this ScheduledTask. :type: str NrK)r=r#r?r?r@r#s cCs|jS)z Gets the num_occurrences of this ScheduledTask. Number of execution occurrences. :return: The num_occurrences of this ScheduledTask. :rtype: int r5rDr?r?r@r$s zScheduledTask.num_occurrencescCs ||_dS)z Sets the num_occurrences of this ScheduledTask. Number of execution occurrences. :param num_occurrences: The num_occurrences of this ScheduledTask. :type: int NrL)r=r$r?r?r@r$s cCs|jS)a" **[Required]** Gets the compartment_id of this ScheduledTask. Compartment Identifier `OCID]`__. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :return: The compartment_id of this ScheduledTask. :rtype: str r6rDr?r?r@r% s zScheduledTask.compartment_idcCs ||_dS)a  Sets the compartment_id of this ScheduledTask. Compartment Identifier `OCID]`__. __ https://docs.cloud.oracle.com/iaas/Content/General/Concepts/identifiers.htm :param compartment_id: The compartment_id of this ScheduledTask. :type: str NrM)r=r%r?r?r@r%s cCs|jS)z **[Required]** Gets the time_created of this ScheduledTask. The date and time the scheduled task was created, in the format defined by RFC3339. :return: The time_created of this ScheduledTask. :rtype: datetime r7rDr?r?r@r&'s zScheduledTask.time_createdcCs ||_dS)z Sets the time_created of this ScheduledTask. The date and time the scheduled task was created, in the format defined by RFC3339. :param time_created: The time_created of this ScheduledTask. :type: datetime NrN)r=r&r?r?r@r&3s cCs|jS)a **[Required]** Gets the time_updated of this ScheduledTask. The date and time the scheduled task was last updated, in the format defined by RFC3339. :return: The time_updated of this ScheduledTask. :rtype: datetime r8rDr?r?r@r'?s zScheduledTask.time_updatedcCs ||_dS)z Sets the time_updated of this ScheduledTask. The date and time the scheduled task was last updated, in the format defined by RFC3339. :param time_updated: The time_updated of this ScheduledTask. :type: datetime NrO)r=r'r?r?r@r'Ks cCs|jS)a Gets the time_of_next_execution of this ScheduledTask. The date and time the scheduled task will execute next, in the format defined by RFC3339. :return: The time_of_next_execution of this ScheduledTask. :rtype: datetime r9rDr?r?r@r(Ws z$ScheduledTask.time_of_next_executioncCs ||_dS)a% Sets the time_of_next_execution of this ScheduledTask. The date and time the scheduled task will execute next, in the format defined by RFC3339. :param time_of_next_execution: The time_of_next_execution of this ScheduledTask. :type: datetime NrP)r=r(r?r?r@r(ds cCs|jS)a **[Required]** Gets the lifecycle_state of this ScheduledTask. The current state of the scheduled task. Allowed values for this property are: "ACTIVE", "DELETED", 'UNKNOWN_ENUM_VALUE'. Any unrecognized values returned by a service will be mapped to 'UNKNOWN_ENUM_VALUE'. :return: The lifecycle_state of this ScheduledTask. :rtype: str )r:rDr?r?r@r)qs zScheduledTask.lifecycle_statecCs ddg}t||sd}||_dS)z Sets the lifecycle_state of this ScheduledTask. The current state of the scheduled task. :param lifecycle_state: The lifecycle_state of this ScheduledTask. :type: str rrrEN)rr:)r=r)rFr?r?r@r)s  cCs|jS)aA Gets the freeform_tags of this ScheduledTask. Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: `{"bar-key": "value"}` :return: The freeform_tags of this ScheduledTask. :rtype: dict(str, str) r;rDr?r?r@r*s zScheduledTask.freeform_tagscCs ||_dS)aM Sets the freeform_tags of this ScheduledTask. Simple key-value pair that is applied without any predefined name, type or scope. Exists for cross-compatibility only. Example: `{"bar-key": "value"}` :param freeform_tags: The freeform_tags of this ScheduledTask. :type: dict(str, str) NrQ)r=r*r?r?r@r*s cCs|jS)a; Gets the defined_tags of this ScheduledTask. Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: `{"foo-namespace": {"bar-key": "value"}}` :return: The defined_tags of this ScheduledTask. :rtype: dict(str, dict(str, object)) r<rDr?r?r@r+s zScheduledTask.defined_tagscCs ||_dS)aF Sets the defined_tags of this ScheduledTask. Defined tags for this resource. Each key is predefined and scoped to a namespace. Example: `{"foo-namespace": {"bar-key": "value"}}` :param defined_tags: The defined_tags of this ScheduledTask. :type: dict(str, dict(str, object)) NrR)r=r+r?r?r@r+s cCst|SN)rrDr?r?r@__repr__szScheduledTask.__repr__cCs|dur dS|j|jkS)NF)__dict__r=otherr?r?r@__eq__szScheduledTask.__eq__cCs ||k SrSr?rVr?r?r@__ne__szScheduledTask.__ne__N)/__name__ __module__ __qualname____doc__ZKIND_ACCELERATIONZ KIND_STANDARDZTASK_TYPE_SAVED_SEARCHZTASK_TYPE_ACCELERATIONZTASK_TYPE_PURGEZTASK_STATUS_READYZTASK_STATUS_PAUSEDZTASK_STATUS_COMPLETEDZTASK_STATUS_BLOCKEDZ(PAUSE_REASON_METRIC_EXTRACTION_NOT_VALIDZ#PAUSE_REASON_SAVED_SEARCH_NOT_VALIDZ#PAUSE_REASON_SAVED_SEARCH_NOT_FOUNDZ#PAUSE_REASON_QUERY_STRING_NOT_VALIDZPAUSE_REASON_USER_ACTIONZPAUSE_REASON_TENANCY_LIFECYCLEZ%PAUSE_REASON_PURGE_RESOURCE_NOT_FOUNDZLIFECYCLE_STATE_ACTIVEZLIFECYCLE_STATE_DELETEDrA staticmethodrCpropertyrsetterrrrrr r!r"r#r$r%r&r'r(r)r*r+rTrXrYr?r?r?r@r s                                   rN)Zoci.utilrrrZoci.decoratorsrobjectrr?r?r?r@s