com.amazonaws.services.securityhub.model.AwsCloudFrontDistributionDetails Maven / Gradle / Ivy
Show all versions of aws-java-sdk-securityhub Show documentation
/*
* Copyright 2016-2021 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.securityhub.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* A distribution configuration.
*
*
* @see AWS API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class AwsCloudFrontDistributionDetails implements Serializable, Cloneable, StructuredPojo {
/**
*
* Provides information about the cache configuration for the distribution.
*
*/
private AwsCloudFrontDistributionCacheBehaviors cacheBehaviors;
/**
*
* The default cache behavior for the configuration.
*
*/
private AwsCloudFrontDistributionDefaultCacheBehavior defaultCacheBehavior;
/**
*
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a viewer
* requests the root URL for the distribution (http://www.example.com) instead of an object in your distribution
* (http://www.example.com/product-description.html).
*
*/
private String defaultRootObject;
/**
*
* The domain name corresponding to the distribution.
*
*/
private String domainName;
/**
*
* The entity tag is a hash of the object.
*
*/
private String eTag;
/**
*
* Indicates when that the distribution was last modified.
*
*
* Uses the date-time
format specified in RFC
* 3339 section 5.6, Internet Date/Time Format. The value cannot contain spaces. For example,
* 2020-03-22T13:22:13.933Z
.
*
*/
private String lastModifiedTime;
/**
*
* A complex type that controls whether access logs are written for the distribution.
*
*/
private AwsCloudFrontDistributionLogging logging;
/**
*
* A complex type that contains information about origins for this distribution.
*
*/
private AwsCloudFrontDistributionOrigins origins;
/**
*
* Provides information about the origin groups in the distribution.
*
*/
private AwsCloudFrontDistributionOriginGroups originGroups;
/**
*
* Indicates the current status of the distribution.
*
*/
private String status;
/**
*
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*
*/
private String webAclId;
/**
*
* Provides information about the cache configuration for the distribution.
*
*
* @param cacheBehaviors
* Provides information about the cache configuration for the distribution.
*/
public void setCacheBehaviors(AwsCloudFrontDistributionCacheBehaviors cacheBehaviors) {
this.cacheBehaviors = cacheBehaviors;
}
/**
*
* Provides information about the cache configuration for the distribution.
*
*
* @return Provides information about the cache configuration for the distribution.
*/
public AwsCloudFrontDistributionCacheBehaviors getCacheBehaviors() {
return this.cacheBehaviors;
}
/**
*
* Provides information about the cache configuration for the distribution.
*
*
* @param cacheBehaviors
* Provides information about the cache configuration for the distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withCacheBehaviors(AwsCloudFrontDistributionCacheBehaviors cacheBehaviors) {
setCacheBehaviors(cacheBehaviors);
return this;
}
/**
*
* The default cache behavior for the configuration.
*
*
* @param defaultCacheBehavior
* The default cache behavior for the configuration.
*/
public void setDefaultCacheBehavior(AwsCloudFrontDistributionDefaultCacheBehavior defaultCacheBehavior) {
this.defaultCacheBehavior = defaultCacheBehavior;
}
/**
*
* The default cache behavior for the configuration.
*
*
* @return The default cache behavior for the configuration.
*/
public AwsCloudFrontDistributionDefaultCacheBehavior getDefaultCacheBehavior() {
return this.defaultCacheBehavior;
}
/**
*
* The default cache behavior for the configuration.
*
*
* @param defaultCacheBehavior
* The default cache behavior for the configuration.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withDefaultCacheBehavior(AwsCloudFrontDistributionDefaultCacheBehavior defaultCacheBehavior) {
setDefaultCacheBehavior(defaultCacheBehavior);
return this;
}
/**
*
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a viewer
* requests the root URL for the distribution (http://www.example.com) instead of an object in your distribution
* (http://www.example.com/product-description.html).
*
*
* @param defaultRootObject
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a
* viewer requests the root URL for the distribution (http://www.example.com) instead of an object in your
* distribution (http://www.example.com/product-description.html).
*/
public void setDefaultRootObject(String defaultRootObject) {
this.defaultRootObject = defaultRootObject;
}
/**
*
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a viewer
* requests the root URL for the distribution (http://www.example.com) instead of an object in your distribution
* (http://www.example.com/product-description.html).
*
*
* @return The object that CloudFront sends in response to requests from the origin (for example, index.html) when a
* viewer requests the root URL for the distribution (http://www.example.com) instead of an object in your
* distribution (http://www.example.com/product-description.html).
*/
public String getDefaultRootObject() {
return this.defaultRootObject;
}
/**
*
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a viewer
* requests the root URL for the distribution (http://www.example.com) instead of an object in your distribution
* (http://www.example.com/product-description.html).
*
*
* @param defaultRootObject
* The object that CloudFront sends in response to requests from the origin (for example, index.html) when a
* viewer requests the root URL for the distribution (http://www.example.com) instead of an object in your
* distribution (http://www.example.com/product-description.html).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withDefaultRootObject(String defaultRootObject) {
setDefaultRootObject(defaultRootObject);
return this;
}
/**
*
* The domain name corresponding to the distribution.
*
*
* @param domainName
* The domain name corresponding to the distribution.
*/
public void setDomainName(String domainName) {
this.domainName = domainName;
}
/**
*
* The domain name corresponding to the distribution.
*
*
* @return The domain name corresponding to the distribution.
*/
public String getDomainName() {
return this.domainName;
}
/**
*
* The domain name corresponding to the distribution.
*
*
* @param domainName
* The domain name corresponding to the distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withDomainName(String domainName) {
setDomainName(domainName);
return this;
}
/**
*
* The entity tag is a hash of the object.
*
*
* @param eTag
* The entity tag is a hash of the object.
*/
public void setETag(String eTag) {
this.eTag = eTag;
}
/**
*
* The entity tag is a hash of the object.
*
*
* @return The entity tag is a hash of the object.
*/
public String getETag() {
return this.eTag;
}
/**
*
* The entity tag is a hash of the object.
*
*
* @param eTag
* The entity tag is a hash of the object.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withETag(String eTag) {
setETag(eTag);
return this;
}
/**
*
* Indicates when that the distribution was last modified.
*
*
* Uses the date-time
format specified in RFC
* 3339 section 5.6, Internet Date/Time Format. The value cannot contain spaces. For example,
* 2020-03-22T13:22:13.933Z
.
*
*
* @param lastModifiedTime
* Indicates when that the distribution was last modified.
*
* Uses the date-time
format specified in RFC 3339 section 5.6, Internet Date/Time
* Format. The value cannot contain spaces. For example, 2020-03-22T13:22:13.933Z
.
*/
public void setLastModifiedTime(String lastModifiedTime) {
this.lastModifiedTime = lastModifiedTime;
}
/**
*
* Indicates when that the distribution was last modified.
*
*
* Uses the date-time
format specified in RFC
* 3339 section 5.6, Internet Date/Time Format. The value cannot contain spaces. For example,
* 2020-03-22T13:22:13.933Z
.
*
*
* @return Indicates when that the distribution was last modified.
*
* Uses the date-time
format specified in RFC 3339 section 5.6, Internet Date/Time
* Format. The value cannot contain spaces. For example, 2020-03-22T13:22:13.933Z
.
*/
public String getLastModifiedTime() {
return this.lastModifiedTime;
}
/**
*
* Indicates when that the distribution was last modified.
*
*
* Uses the date-time
format specified in RFC
* 3339 section 5.6, Internet Date/Time Format. The value cannot contain spaces. For example,
* 2020-03-22T13:22:13.933Z
.
*
*
* @param lastModifiedTime
* Indicates when that the distribution was last modified.
*
* Uses the date-time
format specified in RFC 3339 section 5.6, Internet Date/Time
* Format. The value cannot contain spaces. For example, 2020-03-22T13:22:13.933Z
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withLastModifiedTime(String lastModifiedTime) {
setLastModifiedTime(lastModifiedTime);
return this;
}
/**
*
* A complex type that controls whether access logs are written for the distribution.
*
*
* @param logging
* A complex type that controls whether access logs are written for the distribution.
*/
public void setLogging(AwsCloudFrontDistributionLogging logging) {
this.logging = logging;
}
/**
*
* A complex type that controls whether access logs are written for the distribution.
*
*
* @return A complex type that controls whether access logs are written for the distribution.
*/
public AwsCloudFrontDistributionLogging getLogging() {
return this.logging;
}
/**
*
* A complex type that controls whether access logs are written for the distribution.
*
*
* @param logging
* A complex type that controls whether access logs are written for the distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withLogging(AwsCloudFrontDistributionLogging logging) {
setLogging(logging);
return this;
}
/**
*
* A complex type that contains information about origins for this distribution.
*
*
* @param origins
* A complex type that contains information about origins for this distribution.
*/
public void setOrigins(AwsCloudFrontDistributionOrigins origins) {
this.origins = origins;
}
/**
*
* A complex type that contains information about origins for this distribution.
*
*
* @return A complex type that contains information about origins for this distribution.
*/
public AwsCloudFrontDistributionOrigins getOrigins() {
return this.origins;
}
/**
*
* A complex type that contains information about origins for this distribution.
*
*
* @param origins
* A complex type that contains information about origins for this distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withOrigins(AwsCloudFrontDistributionOrigins origins) {
setOrigins(origins);
return this;
}
/**
*
* Provides information about the origin groups in the distribution.
*
*
* @param originGroups
* Provides information about the origin groups in the distribution.
*/
public void setOriginGroups(AwsCloudFrontDistributionOriginGroups originGroups) {
this.originGroups = originGroups;
}
/**
*
* Provides information about the origin groups in the distribution.
*
*
* @return Provides information about the origin groups in the distribution.
*/
public AwsCloudFrontDistributionOriginGroups getOriginGroups() {
return this.originGroups;
}
/**
*
* Provides information about the origin groups in the distribution.
*
*
* @param originGroups
* Provides information about the origin groups in the distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withOriginGroups(AwsCloudFrontDistributionOriginGroups originGroups) {
setOriginGroups(originGroups);
return this;
}
/**
*
* Indicates the current status of the distribution.
*
*
* @param status
* Indicates the current status of the distribution.
*/
public void setStatus(String status) {
this.status = status;
}
/**
*
* Indicates the current status of the distribution.
*
*
* @return Indicates the current status of the distribution.
*/
public String getStatus() {
return this.status;
}
/**
*
* Indicates the current status of the distribution.
*
*
* @param status
* Indicates the current status of the distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withStatus(String status) {
setStatus(status);
return this;
}
/**
*
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*
*
* @param webAclId
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*/
public void setWebAclId(String webAclId) {
this.webAclId = webAclId;
}
/**
*
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*
*
* @return A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*/
public String getWebAclId() {
return this.webAclId;
}
/**
*
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
*
*
* @param webAclId
* A unique identifier that specifies the WAF web ACL, if any, to associate with this distribution.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public AwsCloudFrontDistributionDetails withWebAclId(String webAclId) {
setWebAclId(webAclId);
return this;
}
/**
* Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
* redacted from this string using a placeholder value.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getCacheBehaviors() != null)
sb.append("CacheBehaviors: ").append(getCacheBehaviors()).append(",");
if (getDefaultCacheBehavior() != null)
sb.append("DefaultCacheBehavior: ").append(getDefaultCacheBehavior()).append(",");
if (getDefaultRootObject() != null)
sb.append("DefaultRootObject: ").append(getDefaultRootObject()).append(",");
if (getDomainName() != null)
sb.append("DomainName: ").append(getDomainName()).append(",");
if (getETag() != null)
sb.append("ETag: ").append(getETag()).append(",");
if (getLastModifiedTime() != null)
sb.append("LastModifiedTime: ").append(getLastModifiedTime()).append(",");
if (getLogging() != null)
sb.append("Logging: ").append(getLogging()).append(",");
if (getOrigins() != null)
sb.append("Origins: ").append(getOrigins()).append(",");
if (getOriginGroups() != null)
sb.append("OriginGroups: ").append(getOriginGroups()).append(",");
if (getStatus() != null)
sb.append("Status: ").append(getStatus()).append(",");
if (getWebAclId() != null)
sb.append("WebAclId: ").append(getWebAclId());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof AwsCloudFrontDistributionDetails == false)
return false;
AwsCloudFrontDistributionDetails other = (AwsCloudFrontDistributionDetails) obj;
if (other.getCacheBehaviors() == null ^ this.getCacheBehaviors() == null)
return false;
if (other.getCacheBehaviors() != null && other.getCacheBehaviors().equals(this.getCacheBehaviors()) == false)
return false;
if (other.getDefaultCacheBehavior() == null ^ this.getDefaultCacheBehavior() == null)
return false;
if (other.getDefaultCacheBehavior() != null && other.getDefaultCacheBehavior().equals(this.getDefaultCacheBehavior()) == false)
return false;
if (other.getDefaultRootObject() == null ^ this.getDefaultRootObject() == null)
return false;
if (other.getDefaultRootObject() != null && other.getDefaultRootObject().equals(this.getDefaultRootObject()) == false)
return false;
if (other.getDomainName() == null ^ this.getDomainName() == null)
return false;
if (other.getDomainName() != null && other.getDomainName().equals(this.getDomainName()) == false)
return false;
if (other.getETag() == null ^ this.getETag() == null)
return false;
if (other.getETag() != null && other.getETag().equals(this.getETag()) == false)
return false;
if (other.getLastModifiedTime() == null ^ this.getLastModifiedTime() == null)
return false;
if (other.getLastModifiedTime() != null && other.getLastModifiedTime().equals(this.getLastModifiedTime()) == false)
return false;
if (other.getLogging() == null ^ this.getLogging() == null)
return false;
if (other.getLogging() != null && other.getLogging().equals(this.getLogging()) == false)
return false;
if (other.getOrigins() == null ^ this.getOrigins() == null)
return false;
if (other.getOrigins() != null && other.getOrigins().equals(this.getOrigins()) == false)
return false;
if (other.getOriginGroups() == null ^ this.getOriginGroups() == null)
return false;
if (other.getOriginGroups() != null && other.getOriginGroups().equals(this.getOriginGroups()) == false)
return false;
if (other.getStatus() == null ^ this.getStatus() == null)
return false;
if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false)
return false;
if (other.getWebAclId() == null ^ this.getWebAclId() == null)
return false;
if (other.getWebAclId() != null && other.getWebAclId().equals(this.getWebAclId()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getCacheBehaviors() == null) ? 0 : getCacheBehaviors().hashCode());
hashCode = prime * hashCode + ((getDefaultCacheBehavior() == null) ? 0 : getDefaultCacheBehavior().hashCode());
hashCode = prime * hashCode + ((getDefaultRootObject() == null) ? 0 : getDefaultRootObject().hashCode());
hashCode = prime * hashCode + ((getDomainName() == null) ? 0 : getDomainName().hashCode());
hashCode = prime * hashCode + ((getETag() == null) ? 0 : getETag().hashCode());
hashCode = prime * hashCode + ((getLastModifiedTime() == null) ? 0 : getLastModifiedTime().hashCode());
hashCode = prime * hashCode + ((getLogging() == null) ? 0 : getLogging().hashCode());
hashCode = prime * hashCode + ((getOrigins() == null) ? 0 : getOrigins().hashCode());
hashCode = prime * hashCode + ((getOriginGroups() == null) ? 0 : getOriginGroups().hashCode());
hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode());
hashCode = prime * hashCode + ((getWebAclId() == null) ? 0 : getWebAclId().hashCode());
return hashCode;
}
@Override
public AwsCloudFrontDistributionDetails clone() {
try {
return (AwsCloudFrontDistributionDetails) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.securityhub.model.transform.AwsCloudFrontDistributionDetailsMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}