Skip to content

Commit

Permalink
[aws-android-sdk-lex] Update models to latest (aws-amplify#1366)
Browse files Browse the repository at this point in the history
  • Loading branch information
awsmobilesdk authored and Karthikeyan committed Dec 9, 2019
1 parent 20afec9 commit 16e47b6
Show file tree
Hide file tree
Showing 4 changed files with 127 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -253,6 +253,13 @@ public class PostContentResult implements Serializable {
*/
private java.io.InputStream audioStream;

/**
* <p>
* The unique identifier for the session.
* </p>
*/
private String sessionId;

/**
* <p>
* Content type as specified in the <code>Accept</code> HTTP header in the
Expand Down Expand Up @@ -2176,6 +2183,51 @@ public PostContentResult withAudioStream(java.io.InputStream audioStream) {
return this;
}

/**
* <p>
* The unique identifier for the session.
* </p>
*
* @return <p>
* The unique identifier for the session.
* </p>
*/
public String getSessionId() {
return sessionId;
}

/**
* <p>
* The unique identifier for the session.
* </p>
*
* @param sessionId <p>
* The unique identifier for the session.
* </p>
*/
public void setSessionId(String sessionId) {
this.sessionId = sessionId;
}

/**
* <p>
* The unique identifier for the session.
* </p>
* <p>
* Returns a reference to this object so that method calls can be chained
* together.
*
* @param sessionId <p>
* The unique identifier for the session.
* </p>
* @return A reference to this updated object so that method calls can be
* chained together.
*/
public PostContentResult withSessionId(String sessionId) {
this.sessionId = sessionId;
return this;
}

/**
* Returns a string representation of this object; useful for testing and
* debugging.
Expand Down Expand Up @@ -2208,7 +2260,9 @@ public String toString() {
if (getInputTranscript() != null)
sb.append("inputTranscript: " + getInputTranscript() + ",");
if (getAudioStream() != null)
sb.append("audioStream: " + getAudioStream());
sb.append("audioStream: " + getAudioStream() + ",");
if (getSessionId() != null)
sb.append("sessionId: " + getSessionId());
sb.append("}");
return sb.toString();
}
Expand Down Expand Up @@ -2237,6 +2291,7 @@ public int hashCode() {
+ ((getInputTranscript() == null) ? 0 : getInputTranscript().hashCode());
hashCode = prime * hashCode
+ ((getAudioStream() == null) ? 0 : getAudioStream().hashCode());
hashCode = prime * hashCode + ((getSessionId() == null) ? 0 : getSessionId().hashCode());
return hashCode;
}

Expand Down Expand Up @@ -2304,6 +2359,11 @@ public boolean equals(Object obj) {
if (other.getAudioStream() != null
&& other.getAudioStream().equals(this.getAudioStream()) == false)
return false;
if (other.getSessionId() == null ^ this.getSessionId() == null)
return false;
if (other.getSessionId() != null
&& other.getSessionId().equals(this.getSessionId()) == false)
return false;
return true;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,13 @@ public class PostTextResult implements Serializable {
*/
private ResponseCard responseCard;

/**
* <p>
* A unique identifier for the session.
* </p>
*/
private String sessionId;

/**
* <p>
* The current user intent that Amazon Lex is aware of.
Expand Down Expand Up @@ -2091,6 +2098,51 @@ public PostTextResult withResponseCard(ResponseCard responseCard) {
return this;
}

/**
* <p>
* A unique identifier for the session.
* </p>
*
* @return <p>
* A unique identifier for the session.
* </p>
*/
public String getSessionId() {
return sessionId;
}

/**
* <p>
* A unique identifier for the session.
* </p>
*
* @param sessionId <p>
* A unique identifier for the session.
* </p>
*/
public void setSessionId(String sessionId) {
this.sessionId = sessionId;
}

/**
* <p>
* A unique identifier for the session.
* </p>
* <p>
* Returns a reference to this object so that method calls can be chained
* together.
*
* @param sessionId <p>
* A unique identifier for the session.
* </p>
* @return A reference to this updated object so that method calls can be
* chained together.
*/
public PostTextResult withSessionId(String sessionId) {
this.sessionId = sessionId;
return this;
}

/**
* Returns a string representation of this object; useful for testing and
* debugging.
Expand Down Expand Up @@ -2119,7 +2171,9 @@ public String toString() {
if (getSlotToElicit() != null)
sb.append("slotToElicit: " + getSlotToElicit() + ",");
if (getResponseCard() != null)
sb.append("responseCard: " + getResponseCard());
sb.append("responseCard: " + getResponseCard() + ",");
if (getSessionId() != null)
sb.append("sessionId: " + getSessionId());
sb.append("}");
return sb.toString();
}
Expand All @@ -2144,6 +2198,7 @@ public int hashCode() {
+ ((getSlotToElicit() == null) ? 0 : getSlotToElicit().hashCode());
hashCode = prime * hashCode
+ ((getResponseCard() == null) ? 0 : getResponseCard().hashCode());
hashCode = prime * hashCode + ((getSessionId() == null) ? 0 : getSessionId().hashCode());
return hashCode;
}

Expand Down Expand Up @@ -2201,6 +2256,11 @@ public boolean equals(Object obj) {
if (other.getResponseCard() != null
&& other.getResponseCard().equals(this.getResponseCard()) == false)
return false;
if (other.getSessionId() == null ^ this.getSessionId() == null)
return false;
if (other.getSessionId() != null
&& other.getSessionId().equals(this.getSessionId()) == false)
return false;
return true;
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,8 @@ public PostContentResult unmarshall(JsonUnmarshallerContext context) throws Exce
java.io.ByteArrayInputStream bis = new java.io.ByteArrayInputStream(bytes);
postContentResult.setAudioStream(bis);
}
if (context.getHeader("x-amz-lex-session-id") != null)
postContentResult.setSessionId(context.getHeader("x-amz-lex-session-id"));
return postContentResult;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,9 @@ public PostTextResult unmarshall(JsonUnmarshallerContext context) throws Excepti
} else if (name.equals("responseCard")) {
postTextResult.setResponseCard(ResponseCardJsonUnmarshaller.getInstance()
.unmarshall(context));
} else if (name.equals("sessionId")) {
postTextResult.setSessionId(StringJsonUnmarshaller.getInstance()
.unmarshall(context));
} else {
reader.skipValue();
}
Expand Down

0 comments on commit 16e47b6

Please sign in to comment.