shiver.me.timbers.aws.dlm.LifecyclePolicy Maven / Gradle / Ivy
package shiver.me.timbers.aws.dlm;
import com.fasterxml.jackson.annotation.JsonIgnore;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;
import shiver.me.timbers.aws.Property;
/**
* LifecyclePolicy
*
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html
*
*/
@JsonInclude(JsonInclude.Include.NON_EMPTY)
@JsonPropertyOrder({
"ExecutionRoleArn",
"Description",
"State",
"PolicyDetails"
})
public class LifecyclePolicy {
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-executionrolearn
*
*/
@JsonProperty("ExecutionRoleArn")
@JsonPropertyDescription("http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-executionrolearn")
private CharSequence executionRoleArn;
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-description
*
*/
@JsonProperty("Description")
@JsonPropertyDescription("http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-description")
private CharSequence description;
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-state
*
*/
@JsonProperty("State")
@JsonPropertyDescription("http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-state")
private CharSequence state;
/**
* LifecyclePolicyPolicyDetails
*
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dlm-lifecyclepolicy-policydetails.html
*
*/
@JsonProperty("PolicyDetails")
@JsonPropertyDescription("http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dlm-lifecyclepolicy-policydetails.html")
private Property policyDetails;
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-executionrolearn
*
*/
@JsonIgnore
public CharSequence getExecutionRoleArn() {
return executionRoleArn;
}
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-executionrolearn
*
*/
@JsonIgnore
public void setExecutionRoleArn(CharSequence executionRoleArn) {
this.executionRoleArn = executionRoleArn;
}
public LifecyclePolicy withExecutionRoleArn(CharSequence executionRoleArn) {
this.executionRoleArn = executionRoleArn;
return this;
}
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-description
*
*/
@JsonIgnore
public CharSequence getDescription() {
return description;
}
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-description
*
*/
@JsonIgnore
public void setDescription(CharSequence description) {
this.description = description;
}
public LifecyclePolicy withDescription(CharSequence description) {
this.description = description;
return this;
}
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-state
*
*/
@JsonIgnore
public CharSequence getState() {
return state;
}
/**
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-resource-dlm-lifecyclepolicy.html#cfn-dlm-lifecyclepolicy-state
*
*/
@JsonIgnore
public void setState(CharSequence state) {
this.state = state;
}
public LifecyclePolicy withState(CharSequence state) {
this.state = state;
return this;
}
/**
* LifecyclePolicyPolicyDetails
*
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dlm-lifecyclepolicy-policydetails.html
*
*/
@JsonIgnore
public Property getPolicyDetails() {
return policyDetails;
}
/**
* LifecyclePolicyPolicyDetails
*
* http://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/aws-properties-dlm-lifecyclepolicy-policydetails.html
*
*/
@JsonIgnore
public void setPolicyDetails(Property policyDetails) {
this.policyDetails = policyDetails;
}
public LifecyclePolicy withPolicyDetails(Property policyDetails) {
this.policyDetails = policyDetails;
return this;
}
@Override
public String toString() {
return new ToStringBuilder(this).append("executionRoleArn", executionRoleArn).append("description", description).append("state", state).append("policyDetails", policyDetails).toString();
}
@Override
public int hashCode() {
return new HashCodeBuilder().append(description).append(state).append(policyDetails).append(executionRoleArn).toHashCode();
}
@Override
public boolean equals(Object other) {
if (other == this) {
return true;
}
if ((other instanceof LifecyclePolicy) == false) {
return false;
}
LifecyclePolicy rhs = ((LifecyclePolicy) other);
return new EqualsBuilder().append(description, rhs.description).append(state, rhs.state).append(policyDetails, rhs.policyDetails).append(executionRoleArn, rhs.executionRoleArn).isEquals();
}
}