/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.dlm.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateLifecyclePolicyRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle policy. *
*/ private String executionRoleArn; /** ** A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. *
*/ private String description; /** ** The desired activation state of the lifecycle policy after creation. *
*/ private String state; /** ** The configuration details of the lifecycle policy. *
*/ private PolicyDetails policyDetails; /** ** The tags to apply to the lifecycle policy during creation. *
*/ private java.util.Map* The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle policy. *
* * @param executionRoleArn * The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle * policy. */ public void setExecutionRoleArn(String executionRoleArn) { this.executionRoleArn = executionRoleArn; } /** ** The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle policy. *
* * @return The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle * policy. */ public String getExecutionRoleArn() { return this.executionRoleArn; } /** ** The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle policy. *
* * @param executionRoleArn * The Amazon Resource Name (ARN) of the IAM role used to run the operations specified by the lifecycle * policy. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateLifecyclePolicyRequest withExecutionRoleArn(String executionRoleArn) { setExecutionRoleArn(executionRoleArn); return this; } /** ** A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. *
* * @param description * A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. */ public void setDescription(String description) { this.description = description; } /** ** A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. *
* * @return A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. */ public String getDescription() { return this.description; } /** ** A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. *
* * @param description * A description of the lifecycle policy. The characters ^[0-9A-Za-z _-]+$ are supported. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateLifecyclePolicyRequest withDescription(String description) { setDescription(description); return this; } /** ** The desired activation state of the lifecycle policy after creation. *
* * @param state * The desired activation state of the lifecycle policy after creation. * @see SettablePolicyStateValues */ public void setState(String state) { this.state = state; } /** ** The desired activation state of the lifecycle policy after creation. *
* * @return The desired activation state of the lifecycle policy after creation. * @see SettablePolicyStateValues */ public String getState() { return this.state; } /** ** The desired activation state of the lifecycle policy after creation. *
* * @param state * The desired activation state of the lifecycle policy after creation. * @return Returns a reference to this object so that method calls can be chained together. * @see SettablePolicyStateValues */ public CreateLifecyclePolicyRequest withState(String state) { setState(state); return this; } /** ** The desired activation state of the lifecycle policy after creation. *
* * @param state * The desired activation state of the lifecycle policy after creation. * @return Returns a reference to this object so that method calls can be chained together. * @see SettablePolicyStateValues */ public CreateLifecyclePolicyRequest withState(SettablePolicyStateValues state) { this.state = state.toString(); return this; } /** ** The configuration details of the lifecycle policy. *
* * @param policyDetails * The configuration details of the lifecycle policy. */ public void setPolicyDetails(PolicyDetails policyDetails) { this.policyDetails = policyDetails; } /** ** The configuration details of the lifecycle policy. *
* * @return The configuration details of the lifecycle policy. */ public PolicyDetails getPolicyDetails() { return this.policyDetails; } /** ** The configuration details of the lifecycle policy. *
* * @param policyDetails * The configuration details of the lifecycle policy. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateLifecyclePolicyRequest withPolicyDetails(PolicyDetails policyDetails) { setPolicyDetails(policyDetails); return this; } /** ** The tags to apply to the lifecycle policy during creation. *
* * @return The tags to apply to the lifecycle policy during creation. */ public java.util.Map* The tags to apply to the lifecycle policy during creation. *
* * @param tags * The tags to apply to the lifecycle policy during creation. */ public void setTags(java.util.Map* The tags to apply to the lifecycle policy during creation. *
* * @param tags * The tags to apply to the lifecycle policy during creation. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateLifecyclePolicyRequest withTags(java.util.Map