public class CustomErrorResponse extends Object implements Serializable, Cloneable
Constructor and Description |
---|
CustomErrorResponse() |
Modifier and Type | Method and Description |
---|---|
CustomErrorResponse |
clone() |
boolean |
equals(Object obj) |
Long |
getErrorCachingMinTTL()
The minimum amount of time you want HTTP error codes to stay in
CloudFront caches before CloudFront queries your origin to see whether
the object has been updated.
|
Integer |
getErrorCode()
The 4xx or 5xx HTTP status code that you want to customize.
|
String |
getResponseCode()
The HTTP status code that you want CloudFront to return with the custom
error page to the viewer.
|
String |
getResponsePagePath()
The path of the custom error page (for example, /custom_404.html).
|
int |
hashCode() |
void |
setErrorCachingMinTTL(Long errorCachingMinTTL)
The minimum amount of time you want HTTP error codes to stay in
CloudFront caches before CloudFront queries your origin to see whether
the object has been updated.
|
void |
setErrorCode(Integer errorCode)
The 4xx or 5xx HTTP status code that you want to customize.
|
void |
setResponseCode(String responseCode)
The HTTP status code that you want CloudFront to return with the custom
error page to the viewer.
|
void |
setResponsePagePath(String responsePagePath)
The path of the custom error page (for example, /custom_404.html).
|
String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
CustomErrorResponse |
withErrorCachingMinTTL(Long errorCachingMinTTL)
The minimum amount of time you want HTTP error codes to stay in
CloudFront caches before CloudFront queries your origin to see whether
the object has been updated.
|
CustomErrorResponse |
withErrorCode(Integer errorCode)
The 4xx or 5xx HTTP status code that you want to customize.
|
CustomErrorResponse |
withResponseCode(String responseCode)
The HTTP status code that you want CloudFront to return with the custom
error page to the viewer.
|
CustomErrorResponse |
withResponsePagePath(String responsePagePath)
The path of the custom error page (for example, /custom_404.html).
|
public void setErrorCode(Integer errorCode)
errorCode
- The 4xx or 5xx HTTP status code that you want to customize. For a
list of HTTP status codes that you can customize, see CloudFront
documentation.public Integer getErrorCode()
public CustomErrorResponse withErrorCode(Integer errorCode)
errorCode
- The 4xx or 5xx HTTP status code that you want to customize. For a
list of HTTP status codes that you can customize, see CloudFront
documentation.public void setResponsePagePath(String responsePagePath)
responsePagePath
- The path of the custom error page (for example, /custom_404.html).
The path is relative to the distribution and must begin with a
slash (/). If the path includes any non-ASCII characters or unsafe
characters as defined in RFC 1783
(http://www.ietf.org/rfc/rfc1738.txt), URL encode those
characters. Do not URL encode any other characters in the path, or
CloudFront will not return the custom error page to the viewer.public String getResponsePagePath()
public CustomErrorResponse withResponsePagePath(String responsePagePath)
responsePagePath
- The path of the custom error page (for example, /custom_404.html).
The path is relative to the distribution and must begin with a
slash (/). If the path includes any non-ASCII characters or unsafe
characters as defined in RFC 1783
(http://www.ietf.org/rfc/rfc1738.txt), URL encode those
characters. Do not URL encode any other characters in the path, or
CloudFront will not return the custom error page to the viewer.public void setResponseCode(String responseCode)
responseCode
- The HTTP status code that you want CloudFront to return with the
custom error page to the viewer. For a list of HTTP status codes
that you can replace, see CloudFront Documentation.public String getResponseCode()
public CustomErrorResponse withResponseCode(String responseCode)
responseCode
- The HTTP status code that you want CloudFront to return with the
custom error page to the viewer. For a list of HTTP status codes
that you can replace, see CloudFront Documentation.public void setErrorCachingMinTTL(Long errorCachingMinTTL)
errorCachingMinTTL
- The minimum amount of time you want HTTP error codes to stay in
CloudFront caches before CloudFront queries your origin to see
whether the object has been updated. You can specify a value from
0 to 31,536,000.public Long getErrorCachingMinTTL()
public CustomErrorResponse withErrorCachingMinTTL(Long errorCachingMinTTL)
errorCachingMinTTL
- The minimum amount of time you want HTTP error codes to stay in
CloudFront caches before CloudFront queries your origin to see
whether the object has been updated. You can specify a value from
0 to 31,536,000.public String toString()
toString
in class Object
Object.toString()
public CustomErrorResponse clone()
Copyright © 2016. All rights reserved.