Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chimesdkidentity Update models to latest #3335

Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,11 @@
*/
public class LexConfiguration implements Serializable {
/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -34,6 +39,13 @@ public class LexConfiguration implements Serializable {
*/
private String respondsTo;

/**
* <p>
* Specifies the type of message that triggers a bot.
* </p>
*/
private InvokedBy invokedBy;

/**
* <p>
* The ARN of the Amazon Lex V2 bot's alias. The ARN uses this format:
Expand Down Expand Up @@ -72,6 +84,11 @@ public class LexConfiguration implements Serializable {
private String welcomeIntent;

/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -80,7 +97,12 @@ public class LexConfiguration implements Serializable {
* <b>Constraints:</b><br/>
* <b>Allowed Values: </b>STANDARD_MESSAGES
*
* @return <p>
* @return <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
* </p>
Expand All @@ -91,6 +113,11 @@ public String getRespondsTo() {
}

/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -99,7 +126,12 @@ public String getRespondsTo() {
* <b>Constraints:</b><br/>
* <b>Allowed Values: </b>STANDARD_MESSAGES
*
* @param respondsTo <p>
* @param respondsTo <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all
* standard messages. Control messages are not supported.
* </p>
Expand All @@ -110,6 +142,11 @@ public void setRespondsTo(String respondsTo) {
}

/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -121,7 +158,12 @@ public void setRespondsTo(String respondsTo) {
* <b>Constraints:</b><br/>
* <b>Allowed Values: </b>STANDARD_MESSAGES
*
* @param respondsTo <p>
* @param respondsTo <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all
* standard messages. Control messages are not supported.
* </p>
Expand All @@ -135,6 +177,11 @@ public LexConfiguration withRespondsTo(String respondsTo) {
}

/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -143,7 +190,12 @@ public LexConfiguration withRespondsTo(String respondsTo) {
* <b>Constraints:</b><br/>
* <b>Allowed Values: </b>STANDARD_MESSAGES
*
* @param respondsTo <p>
* @param respondsTo <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all
* standard messages. Control messages are not supported.
* </p>
Expand All @@ -154,6 +206,11 @@ public void setRespondsTo(RespondsTo respondsTo) {
}

/**
* <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all standard
* messages. Control messages are not supported.
Expand All @@ -165,7 +222,12 @@ public void setRespondsTo(RespondsTo respondsTo) {
* <b>Constraints:</b><br/>
* <b>Allowed Values: </b>STANDARD_MESSAGES
*
* @param respondsTo <p>
* @param respondsTo <important>
* <p>
* <b>Deprecated</b>. Use <code>InvokedBy</code> instead.
* </p>
* </important>
* <p>
* Determines whether the Amazon Lex V2 bot responds to all
* standard messages. Control messages are not supported.
* </p>
Expand All @@ -178,6 +240,51 @@ public LexConfiguration withRespondsTo(RespondsTo respondsTo) {
return this;
}

/**
* <p>
* Specifies the type of message that triggers a bot.
* </p>
*
* @return <p>
* Specifies the type of message that triggers a bot.
* </p>
*/
public InvokedBy getInvokedBy() {
return invokedBy;
}

/**
* <p>
* Specifies the type of message that triggers a bot.
* </p>
*
* @param invokedBy <p>
* Specifies the type of message that triggers a bot.
* </p>
*/
public void setInvokedBy(InvokedBy invokedBy) {
this.invokedBy = invokedBy;
}

/**
* <p>
* Specifies the type of message that triggers a bot.
* </p>
* <p>
* Returns a reference to this object so that method calls can be chained
* together.
*
* @param invokedBy <p>
* Specifies the type of message that triggers a bot.
* </p>
* @return A reference to this updated object so that method calls can be
* chained together.
*/
public LexConfiguration withInvokedBy(InvokedBy invokedBy) {
this.invokedBy = invokedBy;
return this;
}

/**
* <p>
* The ARN of the Amazon Lex V2 bot's alias. The ARN uses this format:
Expand Down Expand Up @@ -401,6 +508,8 @@ public String toString() {
sb.append("{");
if (getRespondsTo() != null)
sb.append("RespondsTo: " + getRespondsTo() + ",");
if (getInvokedBy() != null)
sb.append("InvokedBy: " + getInvokedBy() + ",");
if (getLexBotAliasArn() != null)
sb.append("LexBotAliasArn: " + getLexBotAliasArn() + ",");
if (getLocaleId() != null)
Expand All @@ -417,6 +526,7 @@ public int hashCode() {
int hashCode = 1;

hashCode = prime * hashCode + ((getRespondsTo() == null) ? 0 : getRespondsTo().hashCode());
hashCode = prime * hashCode + ((getInvokedBy() == null) ? 0 : getInvokedBy().hashCode());
hashCode = prime * hashCode
+ ((getLexBotAliasArn() == null) ? 0 : getLexBotAliasArn().hashCode());
hashCode = prime * hashCode + ((getLocaleId() == null) ? 0 : getLocaleId().hashCode());
Expand All @@ -441,6 +551,11 @@ public boolean equals(Object obj) {
if (other.getRespondsTo() != null
&& other.getRespondsTo().equals(this.getRespondsTo()) == false)
return false;
if (other.getInvokedBy() == null ^ this.getInvokedBy() == null)
return false;
if (other.getInvokedBy() != null
&& other.getInvokedBy().equals(this.getInvokedBy()) == false)
return false;
if (other.getLexBotAliasArn() == null ^ this.getLexBotAliasArn() == null)
return false;
if (other.getLexBotAliasArn() != null
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
/*
* Copyright 2010-2023 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.chimesdkidentity.model;

import java.util.HashMap;
import java.util.Map;

/**
* Standard Messages
*/
public enum StandardMessages {

AUTO("AUTO"),
ALL("ALL"),
MENTIONS("MENTIONS"),
NONE("NONE");

private String value;

private StandardMessages(String value) {
this.value = value;
}

@Override
public String toString() {
return value;
}

private static final Map<String, StandardMessages> enumMap;
static {
enumMap = new HashMap<String, StandardMessages>();
enumMap.put("AUTO", AUTO);
enumMap.put("ALL", ALL);
enumMap.put("MENTIONS", MENTIONS);
enumMap.put("NONE", NONE);
}

/**
* Use this in place of valueOf.
*
* @param value real value
* @return StandardMessages corresponding to the value
*/
public static StandardMessages fromValue(String value) {
if (value == null || value.isEmpty()) {
throw new IllegalArgumentException("Value cannot be null or empty!");
} else if (enumMap.containsKey(value)) {
return enumMap.get(value);
} else {
throw new IllegalArgumentException("Cannot create enum from " + value + " value!");
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
/*
* Copyright 2010-2023 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.chimesdkidentity.model;

import java.util.HashMap;
import java.util.Map;

/**
* Targeted Messages
*/
public enum TargetedMessages {

ALL("ALL"),
NONE("NONE");

private String value;

private TargetedMessages(String value) {
this.value = value;
}

@Override
public String toString() {
return value;
}

private static final Map<String, TargetedMessages> enumMap;
static {
enumMap = new HashMap<String, TargetedMessages>();
enumMap.put("ALL", ALL);
enumMap.put("NONE", NONE);
}

/**
* Use this in place of valueOf.
*
* @param value real value
* @return TargetedMessages corresponding to the value
*/
public static TargetedMessages fromValue(String value) {
if (value == null || value.isEmpty()) {
throw new IllegalArgumentException("Value cannot be null or empty!");
} else if (enumMap.containsKey(value)) {
return enumMap.get(value);
} else {
throw new IllegalArgumentException("Cannot create enum from " + value + " value!");
}
}
}
Loading