public class ResponseCard
extends java.lang.Object
implements java.io.Serializable
If you configure a response card when creating your bots, Amazon Lex
substitutes the session attributes and slot values that are available, and
then returns it. The response card can also come from a Lambda function (
dialogCodeHook and fulfillmentActivity on an
intent).
| Constructor and Description |
|---|
ResponseCard() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(java.lang.Object obj) |
java.lang.String |
getContentType()
The content type of the response.
|
java.util.List<GenericAttachment> |
getGenericAttachments()
An array of attachment objects representing options.
|
java.lang.String |
getVersion()
The version of the response card format.
|
int |
hashCode() |
void |
setContentType(ContentType contentType)
The content type of the response.
|
void |
setContentType(java.lang.String contentType)
The content type of the response.
|
void |
setGenericAttachments(java.util.Collection<GenericAttachment> genericAttachments)
An array of attachment objects representing options.
|
void |
setVersion(java.lang.String version)
The version of the response card format.
|
java.lang.String |
toString()
Returns a string representation of this object; useful for testing and
debugging.
|
ResponseCard |
withContentType(ContentType contentType)
The content type of the response.
|
ResponseCard |
withContentType(java.lang.String contentType)
The content type of the response.
|
ResponseCard |
withGenericAttachments(java.util.Collection<GenericAttachment> genericAttachments)
An array of attachment objects representing options.
|
ResponseCard |
withGenericAttachments(GenericAttachment... genericAttachments)
An array of attachment objects representing options.
|
ResponseCard |
withVersion(java.lang.String version)
The version of the response card format.
|
public java.lang.String getVersion()
The version of the response card format.
The version of the response card format.
public void setVersion(java.lang.String version)
The version of the response card format.
version - The version of the response card format.
public ResponseCard withVersion(java.lang.String version)
The version of the response card format.
Returns a reference to this object so that method calls can be chained together.
version - The version of the response card format.
public java.lang.String getContentType()
The content type of the response.
Constraints:
Allowed Values: application/vnd.amazonaws.card.generic
The content type of the response.
ContentTypepublic void setContentType(java.lang.String contentType)
The content type of the response.
Constraints:
Allowed Values: application/vnd.amazonaws.card.generic
contentType - The content type of the response.
ContentTypepublic ResponseCard withContentType(java.lang.String contentType)
The content type of the response.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: application/vnd.amazonaws.card.generic
contentType - The content type of the response.
ContentTypepublic void setContentType(ContentType contentType)
The content type of the response.
Constraints:
Allowed Values: application/vnd.amazonaws.card.generic
contentType - The content type of the response.
ContentTypepublic ResponseCard withContentType(ContentType contentType)
The content type of the response.
Returns a reference to this object so that method calls can be chained together.
Constraints:
Allowed Values: application/vnd.amazonaws.card.generic
contentType - The content type of the response.
ContentTypepublic java.util.List<GenericAttachment> getGenericAttachments()
An array of attachment objects representing options.
An array of attachment objects representing options.
public void setGenericAttachments(java.util.Collection<GenericAttachment> genericAttachments)
An array of attachment objects representing options.
genericAttachments - An array of attachment objects representing options.
public ResponseCard withGenericAttachments(GenericAttachment... genericAttachments)
An array of attachment objects representing options.
Returns a reference to this object so that method calls can be chained together.
genericAttachments - An array of attachment objects representing options.
public ResponseCard withGenericAttachments(java.util.Collection<GenericAttachment> genericAttachments)
An array of attachment objects representing options.
Returns a reference to this object so that method calls can be chained together.
genericAttachments - An array of attachment objects representing options.
public java.lang.String toString()
toString in class java.lang.ObjectObject.toString()public int hashCode()
hashCode in class java.lang.Objectpublic boolean equals(java.lang.Object obj)
equals in class java.lang.ObjectCopyright © 2018 Amazon Web Services, Inc. All Rights Reserved.