/**
 * Cloud Guard APIs
 * A description of the Cloud Guard APIs
 * OpenAPI spec version: 20200131
 *
 *
 * NOTE: This class is auto generated by OracleSDKGenerator.
 * Do not edit the class manually.
 *
 * Copyright (c) 2020, 2022, Oracle and/or its affiliates.  All rights reserved.
 * 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.
 */ import * as serviceRequests from "./request" ; import * as serviceResponses from "./response" ; import * as models from "./model" ; import { CloudGuardClient } from "./client" ; import { genericWaiter , genericTerminalConditionWaiter , WaiterConfiguration } from "oci-common" ; export class CloudGuardWaiter { public constructor ( private client , private readonly config ? ) { } param request param targetStates return public async forDataMaskRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getDataMaskRule ( request ) , response => targetStates . includes ( response . dataMaskRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forDetector ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getDetector ( request ) , response => targetStates . includes ( response . detector . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forDetectorRecipe ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getDetectorRecipe ( request ) , response => targetStates . includes ( response . detectorRecipe . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forDetectorRecipeDetectorRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getDetectorRecipeDetectorRule ( request ) , response => targetStates . includes ( response . detectorRecipeDetectorRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forDetectorRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getDetectorRule ( request ) , response => targetStates . includes ( response . detectorRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forManagedList ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getManagedList ( request ) , response => targetStates . includes ( response . managedList . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forProblem ( request , ... targetStates ) { return genericWaiter ( this . config , ( ) => this . client . getProblem ( request ) , response => targetStates . includes ( response . problem . lifecycleState ! ) ) ; } param request param targetStates return public async forResponderRecipe ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getResponderRecipe ( request ) , response => targetStates . includes ( response . responderRecipe . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forResponderRecipeResponderRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getResponderRecipeResponderRule ( request ) , response => targetStates . includes ( response . responderRecipeResponderRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forResponderRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getResponderRule ( request ) , response => targetStates . includes ( response . responderRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forTarget ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getTarget ( request ) , response => targetStates . includes ( response . target . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forTargetDetectorRecipe ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getTargetDetectorRecipe ( request ) , response => targetStates . includes ( response . targetDetectorRecipe . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forTargetDetectorRecipeDetectorRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getTargetDetectorRecipeDetectorRule ( request ) , response => targetStates . includes ( response . targetDetectorRecipeDetectorRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } param request param targetStates return public async forTargetResponderRecipeResponderRule ( request , ... targetStates ) { return genericTerminalConditionWaiter ( this . config , ( ) => this . client . getTargetResponderRecipeResponderRule ( request ) , response => targetStates . includes ( response . targetResponderRecipeResponderRule . lifecycleState ! ) , targetStates . includes ( models . LifecycleState . Deleted ) ) ; } }