diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessaging.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessaging.java index 35a1fe4af8..b1357f63cb 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessaging.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessaging.java @@ -140,8 +140,10 @@ void associateChannelFlow(AssociateChannelFlowRequest associateChannelFlowReques * @throws ServiceUnavailableException * @throws UnauthorizedClientException * @throws BadRequestException + * @throws NotFoundException * @throws ForbiddenException * @throws ThrottledClientException + * @throws ResourceLimitExceededException * @throws AmazonClientException If any internal errors are encountered * inside the client while attempting to make the request or * handle the response. For example if a network connection is @@ -404,6 +406,7 @@ CreateChannelFlowResult createChannelFlow(CreateChannelFlowRequest createChannel * CreateChannelMembership service method, as returned by Amazon * ChimeSDK Messaging. * @throws BadRequestException + * @throws NotFoundException * @throws ForbiddenException * @throws UnauthorizedClientException * @throws ConflictException @@ -1438,6 +1441,33 @@ ListChannelsModeratedByAppInstanceUserResult listChannelsModeratedByAppInstanceU ListChannelsModeratedByAppInstanceUserRequest listChannelsModeratedByAppInstanceUserRequest) throws AmazonClientException, AmazonServiceException; + /** + *

+ * Lists all the SubChannels in an elastic channel when given a channel ID. + * Available only to the app instance admins and channel moderators of + * elastic channels. + *

+ * + * @param listSubChannelsRequest + * @return listSubChannelsResult The response from the ListSubChannels + * service method, as returned by Amazon ChimeSDK Messaging. + * @throws BadRequestException + * @throws ForbiddenException + * @throws UnauthorizedClientException + * @throws ThrottledClientException + * @throws ServiceUnavailableException + * @throws ServiceFailureException + * @throws AmazonClientException If any internal errors are encountered + * inside the client while attempting to make the request or + * handle the response. For example if a network connection is + * not available. + * @throws AmazonServiceException If an error response is returned by Amazon + * ChimeSDK Messaging indicating either a problem with the data + * in the request, or a server side issue. + */ + ListSubChannelsResult listSubChannels(ListSubChannelsRequest listSubChannelsRequest) + throws AmazonClientException, AmazonServiceException; + /** *

* Lists the tags applied to an Amazon Chime SDK messaging resource. diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessagingClient.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessagingClient.java index 30e65c3ffb..1def5b8677 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessagingClient.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/AmazonChimeSDKMessagingClient.java @@ -437,8 +437,10 @@ public void associateChannelFlow(AssociateChannelFlowRequest associateChannelFlo * @throws ServiceUnavailableException * @throws UnauthorizedClientException * @throws BadRequestException + * @throws NotFoundException * @throws ForbiddenException * @throws ThrottledClientException + * @throws ResourceLimitExceededException * @throws AmazonClientException If any internal errors are encountered * inside the client while attempting to make the request or * handle the response. For example if a network connection is @@ -835,6 +837,7 @@ public CreateChannelFlowResult createChannelFlow( * CreateChannelMembership service method, as returned by Amazon * ChimeSDK Messaging. * @throws BadRequestException + * @throws NotFoundException * @throws ForbiddenException * @throws UnauthorizedClientException * @throws ConflictException @@ -2615,6 +2618,59 @@ public ListChannelsModeratedByAppInstanceUserResult listChannelsModeratedByAppIn } } + /** + *

+ * Lists all the SubChannels in an elastic channel when given a channel ID. + * Available only to the app instance admins and channel moderators of + * elastic channels. + *

+ * + * @param listSubChannelsRequest + * @return listSubChannelsResult The response from the ListSubChannels + * service method, as returned by Amazon ChimeSDK Messaging. + * @throws BadRequestException + * @throws ForbiddenException + * @throws UnauthorizedClientException + * @throws ThrottledClientException + * @throws ServiceUnavailableException + * @throws ServiceFailureException + * @throws AmazonClientException If any internal errors are encountered + * inside the client while attempting to make the request or + * handle the response. For example if a network connection is + * not available. + * @throws AmazonServiceException If an error response is returned by Amazon + * ChimeSDK Messaging indicating either a problem with the data + * in the request, or a server side issue. + */ + public ListSubChannelsResult listSubChannels(ListSubChannelsRequest listSubChannelsRequest) + throws AmazonServiceException, AmazonClientException { + ExecutionContext executionContext = createExecutionContext(listSubChannelsRequest); + AWSRequestMetrics awsRequestMetrics = executionContext.getAwsRequestMetrics(); + awsRequestMetrics.startEvent(Field.ClientExecuteTime); + Request request = null; + Response response = null; + try { + awsRequestMetrics.startEvent(Field.RequestMarshallTime); + try { + request = new ListSubChannelsRequestMarshaller().marshall(listSubChannelsRequest); + // Binds the request metrics to the current request. + request.setAWSRequestMetrics(awsRequestMetrics); + } finally { + awsRequestMetrics.endEvent(Field.RequestMarshallTime); + } + Unmarshaller unmarshaller = new ListSubChannelsResultJsonUnmarshaller(); + JsonResponseHandler responseHandler = new JsonResponseHandler( + unmarshaller); + + response = invoke(request, responseHandler, executionContext); + + return response.getAwsResponse(); + } finally { + awsRequestMetrics.endEvent(Field.ClientExecuteTime); + endClientExecution(awsRequestMetrics, request, response, LOGGING_AWS_REQUEST_METRIC); + } + } + /** *

* Lists the tags applied to an Amazon Chime SDK messaging resource. diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/AppInstanceUserMembershipSummary.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/AppInstanceUserMembershipSummary.java index ea01e5aa95..1e540690d1 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/AppInstanceUserMembershipSummary.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/AppInstanceUserMembershipSummary.java @@ -41,6 +41,18 @@ public class AppInstanceUserMembershipSummary implements Serializable { */ private java.util.Date readMarkerTimestamp; + /** + *

+ * The ID of the SubChannel that the AppInstanceUser is a + * member of. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The type of ChannelMembership. @@ -190,6 +202,69 @@ public AppInstanceUserMembershipSummary withReadMarkerTimestamp( return this; } + /** + *

+ * The ID of the SubChannel that the AppInstanceUser is a + * member of. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel that the AppInstanceUser is + * a member of. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel that the AppInstanceUser is a + * member of. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel that the AppInstanceUser + * is a member of. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel that the AppInstanceUser is a + * member of. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel that the AppInstanceUser + * is a member of. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public AppInstanceUserMembershipSummary withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -204,7 +279,9 @@ public String toString() { if (getType() != null) sb.append("Type: " + getType() + ","); if (getReadMarkerTimestamp() != null) - sb.append("ReadMarkerTimestamp: " + getReadMarkerTimestamp()); + sb.append("ReadMarkerTimestamp: " + getReadMarkerTimestamp() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -217,6 +294,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getReadMarkerTimestamp() == null) ? 0 : getReadMarkerTimestamp().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -240,6 +319,11 @@ public boolean equals(Object obj) { if (other.getReadMarkerTimestamp() != null && other.getReadMarkerTimestamp().equals(this.getReadMarkerTimestamp()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchChannelMemberships.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchChannelMemberships.java index f18de2eed4..c7c2d99357 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchChannelMemberships.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchChannelMemberships.java @@ -61,6 +61,17 @@ public class BatchChannelMemberships implements Serializable { */ private String channelArn; + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The identifier of the member who invited another member. @@ -340,6 +351,63 @@ public BatchChannelMemberships withChannelArn(String channelArn) { return this; } + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public BatchChannelMemberships withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -358,7 +426,9 @@ public String toString() { if (getMembers() != null) sb.append("Members: " + getMembers() + ","); if (getChannelArn() != null) - sb.append("ChannelArn: " + getChannelArn()); + sb.append("ChannelArn: " + getChannelArn() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -372,6 +442,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getMembers() == null) ? 0 : getMembers().hashCode()); hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -404,6 +476,11 @@ public boolean equals(Object obj) { if (other.getChannelArn() != null && other.getChannelArn().equals(this.getChannelArn()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchCreateChannelMembershipRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchCreateChannelMembershipRequest.java index 2169fae123..5777395a00 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchCreateChannelMembershipRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/BatchCreateChannelMembershipRequest.java @@ -75,6 +75,23 @@ public class BatchCreateChannelMembershipRequest extends AmazonWebServiceRequest */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel to which you're adding users. @@ -439,6 +456,99 @@ public BatchCreateChannelMembershipRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public BatchCreateChannelMembershipRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -457,7 +567,9 @@ public String toString() { if (getMemberArns() != null) sb.append("MemberArns: " + getMemberArns() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -472,6 +584,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMemberArns() == null) ? 0 : getMemberArns().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -505,6 +619,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/Channel.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/Channel.java index 7256cded05..d42f47971d 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/Channel.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/Channel.java @@ -120,6 +120,14 @@ public class Channel implements Serializable { */ private String channelFlowArn; + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million members. + *

+ */ + private ElasticChannelConfiguration elasticChannelConfiguration; + /** *

* The name of a channel. @@ -742,6 +750,62 @@ public Channel withChannelFlowArn(String channelFlowArn) { return this; } + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million members. + *

+ * + * @return

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * members. + *

+ */ + public ElasticChannelConfiguration getElasticChannelConfiguration() { + return elasticChannelConfiguration; + } + + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million members. + *

+ * + * @param elasticChannelConfiguration

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * members. + *

+ */ + public void setElasticChannelConfiguration( + ElasticChannelConfiguration elasticChannelConfiguration) { + this.elasticChannelConfiguration = elasticChannelConfiguration; + } + + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million members. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + * + * @param elasticChannelConfiguration

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * members. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public Channel withElasticChannelConfiguration( + ElasticChannelConfiguration elasticChannelConfiguration) { + this.elasticChannelConfiguration = elasticChannelConfiguration; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -772,7 +836,9 @@ public String toString() { if (getLastUpdatedTimestamp() != null) sb.append("LastUpdatedTimestamp: " + getLastUpdatedTimestamp() + ","); if (getChannelFlowArn() != null) - sb.append("ChannelFlowArn: " + getChannelFlowArn()); + sb.append("ChannelFlowArn: " + getChannelFlowArn() + ","); + if (getElasticChannelConfiguration() != null) + sb.append("ElasticChannelConfiguration: " + getElasticChannelConfiguration()); sb.append("}"); return sb.toString(); } @@ -796,6 +862,10 @@ public int hashCode() { + ((getLastUpdatedTimestamp() == null) ? 0 : getLastUpdatedTimestamp().hashCode()); hashCode = prime * hashCode + ((getChannelFlowArn() == null) ? 0 : getChannelFlowArn().hashCode()); + hashCode = prime + * hashCode + + ((getElasticChannelConfiguration() == null) ? 0 + : getElasticChannelConfiguration().hashCode()); return hashCode; } @@ -856,6 +926,13 @@ public boolean equals(Object obj) { if (other.getChannelFlowArn() != null && other.getChannelFlowArn().equals(this.getChannelFlowArn()) == false) return false; + if (other.getElasticChannelConfiguration() == null + ^ this.getElasticChannelConfiguration() == null) + return false; + if (other.getElasticChannelConfiguration() != null + && other.getElasticChannelConfiguration().equals( + this.getElasticChannelConfiguration()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMembership.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMembership.java index e46042abb5..504e3212dd 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMembership.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMembership.java @@ -74,6 +74,17 @@ public class ChannelMembership implements Serializable { */ private java.util.Date lastUpdatedTimestamp; + /** + *

+ * The ID of the SubChannel that a user belongs to. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The identifier of the member who invited another member. @@ -414,6 +425,63 @@ public ChannelMembership withLastUpdatedTimestamp(java.util.Date lastUpdatedTime return this; } + /** + *

+ * The ID of the SubChannel that a user belongs to. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel that a user belongs to. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel that a user belongs to. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel that a user belongs to. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel that a user belongs to. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel that a user belongs to. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ChannelMembership withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -436,7 +504,9 @@ public String toString() { if (getCreatedTimestamp() != null) sb.append("CreatedTimestamp: " + getCreatedTimestamp() + ","); if (getLastUpdatedTimestamp() != null) - sb.append("LastUpdatedTimestamp: " + getLastUpdatedTimestamp()); + sb.append("LastUpdatedTimestamp: " + getLastUpdatedTimestamp() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -454,6 +524,8 @@ public int hashCode() { + ((getCreatedTimestamp() == null) ? 0 : getCreatedTimestamp().hashCode()); hashCode = prime * hashCode + ((getLastUpdatedTimestamp() == null) ? 0 : getLastUpdatedTimestamp().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -496,6 +568,11 @@ public boolean equals(Object obj) { if (other.getLastUpdatedTimestamp() != null && other.getLastUpdatedTimestamp().equals(this.getLastUpdatedTimestamp()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessage.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessage.java index a57d0c2590..c54a7aea7f 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessage.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessage.java @@ -140,6 +140,17 @@ public class ChannelMessage implements Serializable { */ private java.util.Map messageAttributes; + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -948,6 +959,63 @@ public ChannelMessage clearMessageAttributesEntries() { return this; } + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ChannelMessage withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -984,7 +1052,9 @@ public String toString() { if (getStatus() != null) sb.append("Status: " + getStatus() + ","); if (getMessageAttributes() != null) - sb.append("MessageAttributes: " + getMessageAttributes()); + sb.append("MessageAttributes: " + getMessageAttributes() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -1012,6 +1082,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getMessageAttributes() == null) ? 0 : getMessageAttributes().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -1085,6 +1157,11 @@ public boolean equals(Object obj) { if (other.getMessageAttributes() != null && other.getMessageAttributes().equals(this.getMessageAttributes()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessageCallback.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessageCallback.java index ef23c9e2df..abbe7ce241 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessageCallback.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ChannelMessageCallback.java @@ -72,6 +72,17 @@ public class ChannelMessageCallback implements Serializable { */ private java.util.Map messageAttributes; + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The message ID. @@ -386,6 +397,63 @@ public ChannelMessageCallback clearMessageAttributesEntries() { return this; } + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ChannelMessageCallback withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -406,7 +474,9 @@ public String toString() { if (getPushNotification() != null) sb.append("PushNotification: " + getPushNotification() + ","); if (getMessageAttributes() != null) - sb.append("MessageAttributes: " + getMessageAttributes()); + sb.append("MessageAttributes: " + getMessageAttributes() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -423,6 +493,8 @@ public int hashCode() { + ((getPushNotification() == null) ? 0 : getPushNotification().hashCode()); hashCode = prime * hashCode + ((getMessageAttributes() == null) ? 0 : getMessageAttributes().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -460,6 +532,11 @@ public boolean equals(Object obj) { if (other.getMessageAttributes() != null && other.getMessageAttributes().equals(this.getMessageAttributes()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipRequest.java index 24c71f3cea..6c30014e0a 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipRequest.java @@ -132,6 +132,23 @@ public class CreateChannelMembershipRequest extends AmazonWebServiceRequest impl */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel to which you're adding users. @@ -482,6 +499,99 @@ public CreateChannelMembershipRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a moderator in + * an elastic channel. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when creating membership in a SubChannel for a + * moderator in an elastic channel. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public CreateChannelMembershipRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -500,7 +610,9 @@ public String toString() { if (getType() != null) sb.append("Type: " + getType() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -515,6 +627,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -548,6 +662,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipResult.java index d09e6412ee..d4ae9ebd52 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelMembershipResult.java @@ -38,6 +38,17 @@ public class CreateChannelMembershipResult implements Serializable { */ private Identity member; + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -146,6 +157,63 @@ public CreateChannelMembershipResult withMember(Identity member) { return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public CreateChannelMembershipResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -160,7 +228,9 @@ public String toString() { if (getChannelArn() != null) sb.append("ChannelArn: " + getChannelArn() + ","); if (getMember() != null) - sb.append("Member: " + getMember()); + sb.append("Member: " + getMember() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -172,6 +242,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getMember() == null) ? 0 : getMember().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -195,6 +267,11 @@ public boolean equals(Object obj) { return false; if (other.getMember() != null && other.getMember().equals(this.getMember()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelRequest.java index 0a0cb2d114..d4b260906b 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/CreateChannelRequest.java @@ -152,6 +152,15 @@ public class CreateChannelRequest extends AmazonWebServiceRequest implements Ser */ private java.util.List moderatorArns; + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million users, excluding + * moderators. + *

+ */ + private ElasticChannelConfiguration elasticChannelConfiguration; + /** *

* The ARN of the channel request. @@ -993,6 +1002,65 @@ public CreateChannelRequest withModeratorArns(java.util.Collection moder return this; } + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million users, excluding + * moderators. + *

+ * + * @return

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * users, excluding moderators. + *

+ */ + public ElasticChannelConfiguration getElasticChannelConfiguration() { + return elasticChannelConfiguration; + } + + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million users, excluding + * moderators. + *

+ * + * @param elasticChannelConfiguration

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * users, excluding moderators. + *

+ */ + public void setElasticChannelConfiguration( + ElasticChannelConfiguration elasticChannelConfiguration) { + this.elasticChannelConfiguration = elasticChannelConfiguration; + } + + /** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million users, excluding + * moderators. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + * + * @param elasticChannelConfiguration

+ * The attributes required to configure and create an elastic + * channel. An elastic channel can support a maximum of 1-million + * users, excluding moderators. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public CreateChannelRequest withElasticChannelConfiguration( + ElasticChannelConfiguration elasticChannelConfiguration) { + this.elasticChannelConfiguration = elasticChannelConfiguration; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -1025,7 +1093,9 @@ public String toString() { if (getMemberArns() != null) sb.append("MemberArns: " + getMemberArns() + ","); if (getModeratorArns() != null) - sb.append("ModeratorArns: " + getModeratorArns()); + sb.append("ModeratorArns: " + getModeratorArns() + ","); + if (getElasticChannelConfiguration() != null) + sb.append("ElasticChannelConfiguration: " + getElasticChannelConfiguration()); sb.append("}"); return sb.toString(); } @@ -1050,6 +1120,10 @@ public int hashCode() { hashCode = prime * hashCode + ((getMemberArns() == null) ? 0 : getMemberArns().hashCode()); hashCode = prime * hashCode + ((getModeratorArns() == null) ? 0 : getModeratorArns().hashCode()); + hashCode = prime + * hashCode + + ((getElasticChannelConfiguration() == null) ? 0 + : getElasticChannelConfiguration().hashCode()); return hashCode; } @@ -1114,6 +1188,13 @@ public boolean equals(Object obj) { if (other.getModeratorArns() != null && other.getModeratorArns().equals(this.getModeratorArns()) == false) return false; + if (other.getElasticChannelConfiguration() == null + ^ this.getElasticChannelConfiguration() == null) + return false; + if (other.getElasticChannelConfiguration() != null + && other.getElasticChannelConfiguration().equals( + this.getElasticChannelConfiguration()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMembershipRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMembershipRequest.java index 0e6764e783..46db017f78 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMembershipRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMembershipRequest.java @@ -72,6 +72,22 @@ public class DeleteChannelMembershipRequest extends AmazonWebServiceRequest impl */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel from which you want to remove the user. @@ -270,6 +286,93 @@ public DeleteChannelMembershipRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only for use by moderators. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public DeleteChannelMembershipRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -286,7 +389,9 @@ public String toString() { if (getMemberArn() != null) sb.append("MemberArn: " + getMemberArn() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -300,6 +405,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMemberArn() == null) ? 0 : getMemberArn().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -329,6 +436,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMessageRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMessageRequest.java index 4b57cb79dc..c80e99d9e9 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMessageRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelMessageRequest.java @@ -71,6 +71,23 @@ public class DeleteChannelMessageRequest extends AmazonWebServiceRequest impleme */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -257,6 +274,99 @@ public DeleteChannelMessageRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when deleting messages in a SubChannel that the + * user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public DeleteChannelMessageRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -273,7 +383,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -287,6 +399,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -316,6 +430,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelRequest.java index 72ed7f15fa..61f135568f 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DeleteChannelRequest.java @@ -59,6 +59,17 @@ public class DeleteChannelRequest extends AmazonWebServiceRequest implements Ser */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel being deleted. @@ -188,6 +199,63 @@ public DeleteChannelRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public DeleteChannelRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -202,7 +270,9 @@ public String toString() { if (getChannelArn() != null) sb.append("ChannelArn: " + getChannelArn() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -215,6 +285,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -239,6 +311,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DescribeChannelMembershipRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DescribeChannelMembershipRequest.java index 1c897ecd2e..0f90346237 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DescribeChannelMembershipRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/DescribeChannelMembershipRequest.java @@ -72,6 +72,23 @@ public class DescribeChannelMembershipRequest extends AmazonWebServiceRequest im */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. The response contains an + * ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -264,6 +281,99 @@ public DescribeChannelMembershipRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. The response contains an + * ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. The response contains an + * ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. The response contains an + * ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. The response contains + * an ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. The response contains an + * ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. The response contains + * an ElasticChannelConfiguration object. + *

+ * + *

+ * Only required to get a user’s SubChannel membership details. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public DescribeChannelMembershipRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -280,7 +390,9 @@ public String toString() { if (getMemberArn() != null) sb.append("MemberArn: " + getMemberArn() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -294,6 +406,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMemberArn() == null) ? 0 : getMemberArn().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -323,6 +437,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ElasticChannelConfiguration.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ElasticChannelConfiguration.java new file mode 100644 index 0000000000..6e22b3d5b2 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ElasticChannelConfiguration.java @@ -0,0 +1,316 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model; + +import java.io.Serializable; + +/** + *

+ * The attributes required to configure and create an elastic channel. An + * elastic channel can support a maximum of 1-million members. + *

+ */ +public class ElasticChannelConfiguration implements Serializable { + /** + *

+ * The maximum number of SubChannels that you want to allow in the elastic + * channel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ */ + private Integer maximumSubChannels; + + /** + *

+ * The maximum number of members allowed in a SubChannel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ */ + private Integer targetMembershipsPerSubChannel; + + /** + *

+ * The minimum allowed percentage of TargetMembershipsPerSubChannel users. + * Ceil of the calculated value is used in balancing members among + * SubChannels of the elastic channel. + *

+ *

+ * Constraints:
+ * Range: 1 - 40
+ */ + private Integer minimumMembershipPercentage; + + /** + *

+ * The maximum number of SubChannels that you want to allow in the elastic + * channel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ * + * @return

+ * The maximum number of SubChannels that you want to allow in the + * elastic channel. + *

+ */ + public Integer getMaximumSubChannels() { + return maximumSubChannels; + } + + /** + *

+ * The maximum number of SubChannels that you want to allow in the elastic + * channel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ * + * @param maximumSubChannels

+ * The maximum number of SubChannels that you want to allow in + * the elastic channel. + *

+ */ + public void setMaximumSubChannels(Integer maximumSubChannels) { + this.maximumSubChannels = maximumSubChannels; + } + + /** + *

+ * The maximum number of SubChannels that you want to allow in the elastic + * channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Range: 2 -
+ * + * @param maximumSubChannels

+ * The maximum number of SubChannels that you want to allow in + * the elastic channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ElasticChannelConfiguration withMaximumSubChannels(Integer maximumSubChannels) { + this.maximumSubChannels = maximumSubChannels; + return this; + } + + /** + *

+ * The maximum number of members allowed in a SubChannel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ * + * @return

+ * The maximum number of members allowed in a SubChannel. + *

+ */ + public Integer getTargetMembershipsPerSubChannel() { + return targetMembershipsPerSubChannel; + } + + /** + *

+ * The maximum number of members allowed in a SubChannel. + *

+ *

+ * Constraints:
+ * Range: 2 -
+ * + * @param targetMembershipsPerSubChannel

+ * The maximum number of members allowed in a SubChannel. + *

+ */ + public void setTargetMembershipsPerSubChannel(Integer targetMembershipsPerSubChannel) { + this.targetMembershipsPerSubChannel = targetMembershipsPerSubChannel; + } + + /** + *

+ * The maximum number of members allowed in a SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Range: 2 -
+ * + * @param targetMembershipsPerSubChannel

+ * The maximum number of members allowed in a SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ElasticChannelConfiguration withTargetMembershipsPerSubChannel( + Integer targetMembershipsPerSubChannel) { + this.targetMembershipsPerSubChannel = targetMembershipsPerSubChannel; + return this; + } + + /** + *

+ * The minimum allowed percentage of TargetMembershipsPerSubChannel users. + * Ceil of the calculated value is used in balancing members among + * SubChannels of the elastic channel. + *

+ *

+ * Constraints:
+ * Range: 1 - 40
+ * + * @return

+ * The minimum allowed percentage of TargetMembershipsPerSubChannel + * users. Ceil of the calculated value is used in balancing members + * among SubChannels of the elastic channel. + *

+ */ + public Integer getMinimumMembershipPercentage() { + return minimumMembershipPercentage; + } + + /** + *

+ * The minimum allowed percentage of TargetMembershipsPerSubChannel users. + * Ceil of the calculated value is used in balancing members among + * SubChannels of the elastic channel. + *

+ *

+ * Constraints:
+ * Range: 1 - 40
+ * + * @param minimumMembershipPercentage

+ * The minimum allowed percentage of + * TargetMembershipsPerSubChannel users. Ceil of the calculated + * value is used in balancing members among SubChannels of the + * elastic channel. + *

+ */ + public void setMinimumMembershipPercentage(Integer minimumMembershipPercentage) { + this.minimumMembershipPercentage = minimumMembershipPercentage; + } + + /** + *

+ * The minimum allowed percentage of TargetMembershipsPerSubChannel users. + * Ceil of the calculated value is used in balancing members among + * SubChannels of the elastic channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Range: 1 - 40
+ * + * @param minimumMembershipPercentage

+ * The minimum allowed percentage of + * TargetMembershipsPerSubChannel users. Ceil of the calculated + * value is used in balancing members among SubChannels of the + * elastic channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ElasticChannelConfiguration withMinimumMembershipPercentage( + Integer minimumMembershipPercentage) { + this.minimumMembershipPercentage = minimumMembershipPercentage; + return this; + } + + /** + * Returns a string representation of this object; useful for testing and + * debugging. + * + * @return A string representation of this object. + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("{"); + if (getMaximumSubChannels() != null) + sb.append("MaximumSubChannels: " + getMaximumSubChannels() + ","); + if (getTargetMembershipsPerSubChannel() != null) + sb.append("TargetMembershipsPerSubChannel: " + getTargetMembershipsPerSubChannel() + + ","); + if (getMinimumMembershipPercentage() != null) + sb.append("MinimumMembershipPercentage: " + getMinimumMembershipPercentage()); + sb.append("}"); + return sb.toString(); + } + + @Override + public int hashCode() { + final int prime = 31; + int hashCode = 1; + + hashCode = prime * hashCode + + ((getMaximumSubChannels() == null) ? 0 : getMaximumSubChannels().hashCode()); + hashCode = prime + * hashCode + + ((getTargetMembershipsPerSubChannel() == null) ? 0 + : getTargetMembershipsPerSubChannel().hashCode()); + hashCode = prime + * hashCode + + ((getMinimumMembershipPercentage() == null) ? 0 + : getMinimumMembershipPercentage().hashCode()); + return hashCode; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + + if (obj instanceof ElasticChannelConfiguration == false) + return false; + ElasticChannelConfiguration other = (ElasticChannelConfiguration) obj; + + if (other.getMaximumSubChannels() == null ^ this.getMaximumSubChannels() == null) + return false; + if (other.getMaximumSubChannels() != null + && other.getMaximumSubChannels().equals(this.getMaximumSubChannels()) == false) + return false; + if (other.getTargetMembershipsPerSubChannel() == null + ^ this.getTargetMembershipsPerSubChannel() == null) + return false; + if (other.getTargetMembershipsPerSubChannel() != null + && other.getTargetMembershipsPerSubChannel().equals( + this.getTargetMembershipsPerSubChannel()) == false) + return false; + if (other.getMinimumMembershipPercentage() == null + ^ this.getMinimumMembershipPercentage() == null) + return false; + if (other.getMinimumMembershipPercentage() != null + && other.getMinimumMembershipPercentage().equals( + this.getMinimumMembershipPercentage()) == false) + return false; + return true; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageRequest.java index 00d1f87329..5e48d49f3e 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageRequest.java @@ -69,6 +69,23 @@ public class GetChannelMessageRequest extends AmazonWebServiceRequest implements */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the user belongs + * to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -255,6 +272,99 @@ public GetChannelMessageRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the user belongs + * to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the user + * belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the user belongs + * to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the user belongs + * to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting messages in a SubChannel that the + * user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public GetChannelMessageRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -271,7 +381,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -285,6 +397,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -314,6 +428,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageStatusRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageStatusRequest.java index c13d746d26..31a238bc6d 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageStatusRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/GetChannelMessageStatusRequest.java @@ -116,6 +116,23 @@ public class GetChannelMessageStatusRequest extends AmazonWebServiceRequest impl */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel @@ -302,6 +319,99 @@ public GetChannelMessageStatusRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that + * the user belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that + * the user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when getting message status in a SubChannel that + * the user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public GetChannelMessageStatusRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -318,7 +428,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -332,6 +444,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -361,6 +475,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMembershipsRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMembershipsRequest.java index 1402a947fc..b01fd646ea 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMembershipsRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMembershipsRequest.java @@ -100,6 +100,23 @@ public class ListChannelMembershipsRequest extends AmazonWebServiceRequest imple */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a particular + * sub-channel of an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The maximum number of channel memberships that you want returned. @@ -491,6 +508,99 @@ public ListChannelMembershipsRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a particular + * sub-channel of an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a particular + * sub-channel of an elastic channel. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a particular + * sub-channel of an elastic channel. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a + * particular sub-channel of an elastic channel. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a particular + * sub-channel of an elastic channel. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing a user's memberships in a + * particular sub-channel of an elastic channel. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListChannelMembershipsRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -511,7 +621,9 @@ public String toString() { if (getNextToken() != null) sb.append("NextToken: " + getNextToken() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -527,6 +639,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -565,6 +679,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesRequest.java index fb2c805252..06c4a7883c 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesRequest.java @@ -112,6 +112,23 @@ public class ListChannelMessagesRequest extends AmazonWebServiceRequest implemen */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -557,6 +574,99 @@ public ListChannelMessagesRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that + * the user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when listing the messages in a SubChannel that + * the user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListChannelMessagesRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -581,7 +691,9 @@ public String toString() { if (getNextToken() != null) sb.append("NextToken: " + getNextToken() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -599,6 +711,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -647,6 +761,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesResult.java index 18d4346075..8ccdc6caa0 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListChannelMessagesResult.java @@ -50,6 +50,17 @@ public class ListChannelMessagesResult implements Serializable { */ private java.util.List channelMessages; + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel containing the requested messages. @@ -252,6 +263,63 @@ public ListChannelMessagesResult withChannelMessages( return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListChannelMessagesResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -268,7 +336,9 @@ public String toString() { if (getNextToken() != null) sb.append("NextToken: " + getNextToken() + ","); if (getChannelMessages() != null) - sb.append("ChannelMessages: " + getChannelMessages()); + sb.append("ChannelMessages: " + getChannelMessages() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -282,6 +352,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); hashCode = prime * hashCode + ((getChannelMessages() == null) ? 0 : getChannelMessages().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -311,6 +383,11 @@ public boolean equals(Object obj) { if (other.getChannelMessages() != null && other.getChannelMessages().equals(this.getChannelMessages()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsRequest.java new file mode 100644 index 0000000000..089ed236b5 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsRequest.java @@ -0,0 +1,393 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model; + +import java.io.Serializable; + +import com.amazonaws.AmazonWebServiceRequest; + +/** + *

+ * Lists all the SubChannels in an elastic channel when given a channel ID. + * Available only to the app instance admins and channel moderators of elastic + * channels. + *

+ */ +public class ListSubChannelsRequest extends AmazonWebServiceRequest implements Serializable { + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ */ + private String channelArn; + + /** + *

+ * The AppInstanceUserArn of the user making the API call. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ */ + private String chimeBearer; + + /** + *

+ * The maximum number of sub-channels that you want to return. + *

+ *

+ * Constraints:
+ * Range: 1 - 50
+ */ + private Integer maxResults; + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ */ + private String nextToken; + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @return

+ * The ARN of elastic channel. + *

+ */ + public String getChannelArn() { + return channelArn; + } + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param channelArn

+ * The ARN of elastic channel. + *

+ */ + public void setChannelArn(String channelArn) { + this.channelArn = channelArn; + } + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param channelArn

+ * The ARN of elastic channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsRequest withChannelArn(String channelArn) { + this.channelArn = channelArn; + return this; + } + + /** + *

+ * The AppInstanceUserArn of the user making the API call. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @return

+ * The AppInstanceUserArn of the user making the API + * call. + *

+ */ + public String getChimeBearer() { + return chimeBearer; + } + + /** + *

+ * The AppInstanceUserArn of the user making the API call. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param chimeBearer

+ * The AppInstanceUserArn of the user making the API + * call. + *

+ */ + public void setChimeBearer(String chimeBearer) { + this.chimeBearer = chimeBearer; + } + + /** + *

+ * The AppInstanceUserArn of the user making the API call. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param chimeBearer

+ * The AppInstanceUserArn of the user making the API + * call. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsRequest withChimeBearer(String chimeBearer) { + this.chimeBearer = chimeBearer; + return this; + } + + /** + *

+ * The maximum number of sub-channels that you want to return. + *

+ *

+ * Constraints:
+ * Range: 1 - 50
+ * + * @return

+ * The maximum number of sub-channels that you want to return. + *

+ */ + public Integer getMaxResults() { + return maxResults; + } + + /** + *

+ * The maximum number of sub-channels that you want to return. + *

+ *

+ * Constraints:
+ * Range: 1 - 50
+ * + * @param maxResults

+ * The maximum number of sub-channels that you want to return. + *

+ */ + public void setMaxResults(Integer maxResults) { + this.maxResults = maxResults; + } + + /** + *

+ * The maximum number of sub-channels that you want to return. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Range: 1 - 50
+ * + * @param maxResults

+ * The maximum number of sub-channels that you want to return. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsRequest withMaxResults(Integer maxResults) { + this.maxResults = maxResults; + return this; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @return

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ */ + public String getNextToken() { + return nextToken; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @param nextToken

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ */ + public void setNextToken(String nextToken) { + this.nextToken = nextToken; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @param nextToken

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsRequest withNextToken(String nextToken) { + this.nextToken = nextToken; + return this; + } + + /** + * Returns a string representation of this object; useful for testing and + * debugging. + * + * @return A string representation of this object. + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("{"); + if (getChannelArn() != null) + sb.append("ChannelArn: " + getChannelArn() + ","); + if (getChimeBearer() != null) + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getMaxResults() != null) + sb.append("MaxResults: " + getMaxResults() + ","); + if (getNextToken() != null) + sb.append("NextToken: " + getNextToken()); + sb.append("}"); + return sb.toString(); + } + + @Override + public int hashCode() { + final int prime = 31; + int hashCode = 1; + + hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); + hashCode = prime * hashCode + + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + ((getMaxResults() == null) ? 0 : getMaxResults().hashCode()); + hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); + return hashCode; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + + if (obj instanceof ListSubChannelsRequest == false) + return false; + ListSubChannelsRequest other = (ListSubChannelsRequest) obj; + + if (other.getChannelArn() == null ^ this.getChannelArn() == null) + return false; + if (other.getChannelArn() != null + && other.getChannelArn().equals(this.getChannelArn()) == false) + return false; + if (other.getChimeBearer() == null ^ this.getChimeBearer() == null) + return false; + if (other.getChimeBearer() != null + && other.getChimeBearer().equals(this.getChimeBearer()) == false) + return false; + if (other.getMaxResults() == null ^ this.getMaxResults() == null) + return false; + if (other.getMaxResults() != null + && other.getMaxResults().equals(this.getMaxResults()) == false) + return false; + if (other.getNextToken() == null ^ this.getNextToken() == null) + return false; + if (other.getNextToken() != null + && other.getNextToken().equals(this.getNextToken()) == false) + return false; + return true; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsResult.java new file mode 100644 index 0000000000..bf6d3d9ff5 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/ListSubChannelsResult.java @@ -0,0 +1,314 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model; + +import java.io.Serializable; + +public class ListSubChannelsResult implements Serializable { + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ */ + private String channelArn; + + /** + *

+ * The information about each sub-channel. + *

+ */ + private java.util.List subChannels; + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ */ + private String nextToken; + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @return

+ * The ARN of elastic channel. + *

+ */ + public String getChannelArn() { + return channelArn; + } + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param channelArn

+ * The ARN of elastic channel. + *

+ */ + public void setChannelArn(String channelArn) { + this.channelArn = channelArn; + } + + /** + *

+ * The ARN of elastic channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 5 - 1600
+ * Pattern: + * arn:[a-z0-9-\.]{1,63}:[a-z0-9-\.]{0,63}:[a-z0-9-\.]{0,63}: + * [a-z0-9-\.]{0,63}:[^/].{0,1023}
+ * + * @param channelArn

+ * The ARN of elastic channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsResult withChannelArn(String channelArn) { + this.channelArn = channelArn; + return this; + } + + /** + *

+ * The information about each sub-channel. + *

+ * + * @return

+ * The information about each sub-channel. + *

+ */ + public java.util.List getSubChannels() { + return subChannels; + } + + /** + *

+ * The information about each sub-channel. + *

+ * + * @param subChannels

+ * The information about each sub-channel. + *

+ */ + public void setSubChannels(java.util.Collection subChannels) { + if (subChannels == null) { + this.subChannels = null; + return; + } + + this.subChannels = new java.util.ArrayList(subChannels); + } + + /** + *

+ * The information about each sub-channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + * + * @param subChannels

+ * The information about each sub-channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsResult withSubChannels(SubChannelSummary... subChannels) { + if (getSubChannels() == null) { + this.subChannels = new java.util.ArrayList(subChannels.length); + } + for (SubChannelSummary value : subChannels) { + this.subChannels.add(value); + } + return this; + } + + /** + *

+ * The information about each sub-channel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + * + * @param subChannels

+ * The information about each sub-channel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsResult withSubChannels(java.util.Collection subChannels) { + setSubChannels(subChannels); + return this; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @return

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ */ + public String getNextToken() { + return nextToken; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @param nextToken

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ */ + public void setNextToken(String nextToken) { + this.nextToken = nextToken; + } + + /** + *

+ * The token passed by previous API calls until all requested sub-channels + * are returned. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 0 - 2048
+ * Pattern: .*
+ * + * @param nextToken

+ * The token passed by previous API calls until all requested + * sub-channels are returned. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public ListSubChannelsResult withNextToken(String nextToken) { + this.nextToken = nextToken; + return this; + } + + /** + * Returns a string representation of this object; useful for testing and + * debugging. + * + * @return A string representation of this object. + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("{"); + if (getChannelArn() != null) + sb.append("ChannelArn: " + getChannelArn() + ","); + if (getSubChannels() != null) + sb.append("SubChannels: " + getSubChannels() + ","); + if (getNextToken() != null) + sb.append("NextToken: " + getNextToken()); + sb.append("}"); + return sb.toString(); + } + + @Override + public int hashCode() { + final int prime = 31; + int hashCode = 1; + + hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); + hashCode = prime * hashCode + + ((getSubChannels() == null) ? 0 : getSubChannels().hashCode()); + hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); + return hashCode; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + + if (obj instanceof ListSubChannelsResult == false) + return false; + ListSubChannelsResult other = (ListSubChannelsResult) obj; + + if (other.getChannelArn() == null ^ this.getChannelArn() == null) + return false; + if (other.getChannelArn() != null + && other.getChannelArn().equals(this.getChannelArn()) == false) + return false; + if (other.getSubChannels() == null ^ this.getSubChannels() == null) + return false; + if (other.getSubChannels() != null + && other.getSubChannels().equals(this.getSubChannels()) == false) + return false; + if (other.getNextToken() == null ^ this.getNextToken() == null) + return false; + if (other.getNextToken() != null + && other.getNextToken().equals(this.getNextToken()) == false) + return false; + return true; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageRequest.java index 4b34b99905..e03973caae 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageRequest.java @@ -70,6 +70,17 @@ public class RedactChannelMessageRequest extends AmazonWebServiceRequest impleme */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel containing the messages that you want to redact. @@ -259,6 +270,63 @@ public RedactChannelMessageRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public RedactChannelMessageRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -275,7 +343,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -289,6 +359,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -318,6 +390,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageResult.java index bdd1974f50..17fd34bbd2 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/RedactChannelMessageResult.java @@ -42,6 +42,23 @@ public class RedactChannelMessageResult implements Serializable { */ private String messageId; + /** + *

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel containing the messages that you want to redact. @@ -165,6 +182,99 @@ public RedactChannelMessageResult withMessageId(String messageId) { return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * + *

+ * Only required when redacting messages in a SubChannel that the + * user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public RedactChannelMessageResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -179,7 +289,9 @@ public String toString() { if (getChannelArn() != null) sb.append("ChannelArn: " + getChannelArn() + ","); if (getMessageId() != null) - sb.append("MessageId: " + getMessageId()); + sb.append("MessageId: " + getMessageId() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -191,6 +303,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -215,6 +329,11 @@ public boolean equals(Object obj) { if (other.getMessageId() != null && other.getMessageId().equals(this.getMessageId()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageRequest.java index a98da71496..f66a7ff3e4 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageRequest.java @@ -133,6 +133,17 @@ public class SendChannelMessageRequest extends AmazonWebServiceRequest implement */ private java.util.Map messageAttributes; + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -786,6 +797,63 @@ public SendChannelMessageRequest clearMessageAttributesEntries() { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public SendChannelMessageRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -814,7 +882,9 @@ public String toString() { if (getPushNotification() != null) sb.append("PushNotification: " + getPushNotification() + ","); if (getMessageAttributes() != null) - sb.append("MessageAttributes: " + getMessageAttributes()); + sb.append("MessageAttributes: " + getMessageAttributes() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -838,6 +908,8 @@ public int hashCode() { + ((getPushNotification() == null) ? 0 : getPushNotification().hashCode()); hashCode = prime * hashCode + ((getMessageAttributes() == null) ? 0 : getMessageAttributes().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -894,6 +966,11 @@ public boolean equals(Object obj) { if (other.getMessageAttributes() != null && other.getMessageAttributes().equals(this.getMessageAttributes()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageResult.java index 12ec962cec..a662a30cd7 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SendChannelMessageResult.java @@ -49,6 +49,17 @@ public class SendChannelMessageResult implements Serializable { */ private ChannelMessageStatusStructure status; + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -214,6 +225,63 @@ public SendChannelMessageResult withStatus(ChannelMessageStatusStructure status) return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public SendChannelMessageResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -230,7 +298,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getStatus() != null) - sb.append("Status: " + getStatus()); + sb.append("Status: " + getStatus() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -243,6 +313,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -271,6 +343,11 @@ public boolean equals(Object obj) { return false; if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SubChannelSummary.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SubChannelSummary.java new file mode 100644 index 0000000000..82c1591e06 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/SubChannelSummary.java @@ -0,0 +1,200 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model; + +import java.io.Serializable; + +/** + *

+ * Summary of the sub-channels associated with the elastic channel. + *

+ */ +public class SubChannelSummary implements Serializable { + /** + *

+ * The unique ID of a SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + + /** + *

+ * The number of members in a SubChannel. + *

+ */ + private Integer membershipCount; + + /** + *

+ * The unique ID of a SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The unique ID of a SubChannel. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The unique ID of a SubChannel. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The unique ID of a SubChannel. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The unique ID of a SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The unique ID of a SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public SubChannelSummary withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + + /** + *

+ * The number of members in a SubChannel. + *

+ * + * @return

+ * The number of members in a SubChannel. + *

+ */ + public Integer getMembershipCount() { + return membershipCount; + } + + /** + *

+ * The number of members in a SubChannel. + *

+ * + * @param membershipCount

+ * The number of members in a SubChannel. + *

+ */ + public void setMembershipCount(Integer membershipCount) { + this.membershipCount = membershipCount; + } + + /** + *

+ * The number of members in a SubChannel. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + * + * @param membershipCount

+ * The number of members in a SubChannel. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public SubChannelSummary withMembershipCount(Integer membershipCount) { + this.membershipCount = membershipCount; + return this; + } + + /** + * Returns a string representation of this object; useful for testing and + * debugging. + * + * @return A string representation of this object. + * @see java.lang.Object#toString() + */ + @Override + public String toString() { + StringBuilder sb = new StringBuilder(); + sb.append("{"); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId() + ","); + if (getMembershipCount() != null) + sb.append("MembershipCount: " + getMembershipCount()); + sb.append("}"); + return sb.toString(); + } + + @Override + public int hashCode() { + final int prime = 31; + int hashCode = 1; + + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); + hashCode = prime * hashCode + + ((getMembershipCount() == null) ? 0 : getMembershipCount().hashCode()); + return hashCode; + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (obj == null) + return false; + + if (obj instanceof SubChannelSummary == false) + return false; + SubChannelSummary other = (SubChannelSummary) obj; + + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; + if (other.getMembershipCount() == null ^ this.getMembershipCount() == null) + return false; + if (other.getMembershipCount() != null + && other.getMembershipCount().equals(this.getMembershipCount()) == false) + return false; + return true; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageRequest.java index dcb8342222..ae83d16c27 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageRequest.java @@ -91,6 +91,23 @@ public class UpdateChannelMessageRequest extends AmazonWebServiceRequest impleme */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -391,6 +408,99 @@ public UpdateChannelMessageRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the + * user belongs to. + *

+ *
+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the user + * belongs to. + *

+ *
+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * + *

+ * Only required when updating messages in a SubChannel that the + * user belongs to. + *

+ *
+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public UpdateChannelMessageRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -411,7 +521,9 @@ public String toString() { if (getMetadata() != null) sb.append("Metadata: " + getMetadata() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -427,6 +539,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getMetadata() == null) ? 0 : getMetadata().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -464,6 +578,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageResult.java index 366a411857..69fdcfd33f 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelMessageResult.java @@ -49,6 +49,17 @@ public class UpdateChannelMessageResult implements Serializable { */ private ChannelMessageStatusStructure status; + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -214,6 +225,63 @@ public UpdateChannelMessageResult withStatus(ChannelMessageStatusStructure statu return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public UpdateChannelMessageResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -230,7 +298,9 @@ public String toString() { if (getMessageId() != null) sb.append("MessageId: " + getMessageId() + ","); if (getStatus() != null) - sb.append("Status: " + getStatus()); + sb.append("Status: " + getStatus() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -243,6 +313,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getMessageId() == null) ? 0 : getMessageId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -271,6 +343,11 @@ public boolean equals(Object obj) { return false; if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerRequest.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerRequest.java index 0f6e8284c6..9237993169 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerRequest.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerRequest.java @@ -58,6 +58,17 @@ public class UpdateChannelReadMarkerRequest extends AmazonWebServiceRequest impl */ private String chimeBearer; + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -187,6 +198,63 @@ public UpdateChannelReadMarkerRequest withChimeBearer(String chimeBearer) { return this; } + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the request. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the request. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the request. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public UpdateChannelReadMarkerRequest withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -201,7 +269,9 @@ public String toString() { if (getChannelArn() != null) sb.append("ChannelArn: " + getChannelArn() + ","); if (getChimeBearer() != null) - sb.append("ChimeBearer: " + getChimeBearer()); + sb.append("ChimeBearer: " + getChimeBearer() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -214,6 +284,8 @@ public int hashCode() { hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); hashCode = prime * hashCode + ((getChimeBearer() == null) ? 0 : getChimeBearer().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -238,6 +310,11 @@ public boolean equals(Object obj) { if (other.getChimeBearer() != null && other.getChimeBearer().equals(this.getChimeBearer()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerResult.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerResult.java index 01f7eb77e2..2cb198bcd2 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerResult.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/UpdateChannelReadMarkerResult.java @@ -31,6 +31,17 @@ public class UpdateChannelReadMarkerResult implements Serializable { */ private String channelArn; + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ */ + private String subChannelId; + /** *

* The ARN of the channel. @@ -94,6 +105,63 @@ public UpdateChannelReadMarkerResult withChannelArn(String channelArn) { return this; } + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @return

+ * The ID of the SubChannel in the response. + *

+ */ + public String getSubChannelId() { + return subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ */ + public void setSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + } + + /** + *

+ * The ID of the SubChannel in the response. + *

+ *

+ * Returns a reference to this object so that method calls can be chained + * together. + *

+ * Constraints:
+ * Length: 1 - 128
+ * Pattern: [-_a-zA-Z0-9]*
+ * + * @param subChannelId

+ * The ID of the SubChannel in the response. + *

+ * @return A reference to this updated object so that method calls can be + * chained together. + */ + public UpdateChannelReadMarkerResult withSubChannelId(String subChannelId) { + this.subChannelId = subChannelId; + return this; + } + /** * Returns a string representation of this object; useful for testing and * debugging. @@ -106,7 +174,9 @@ public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getChannelArn() != null) - sb.append("ChannelArn: " + getChannelArn()); + sb.append("ChannelArn: " + getChannelArn() + ","); + if (getSubChannelId() != null) + sb.append("SubChannelId: " + getSubChannelId()); sb.append("}"); return sb.toString(); } @@ -117,6 +187,8 @@ public int hashCode() { int hashCode = 1; hashCode = prime * hashCode + ((getChannelArn() == null) ? 0 : getChannelArn().hashCode()); + hashCode = prime * hashCode + + ((getSubChannelId() == null) ? 0 : getSubChannelId().hashCode()); return hashCode; } @@ -136,6 +208,11 @@ public boolean equals(Object obj) { if (other.getChannelArn() != null && other.getChannelArn().equals(this.getChannelArn()) == false) return false; + if (other.getSubChannelId() == null ^ this.getSubChannelId() == null) + return false; + if (other.getSubChannelId() != null + && other.getSubChannelId().equals(this.getSubChannelId()) == false) + return false; return true; } } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonMarshaller.java index 6f6b500205..4d2e3e586b 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonMarshaller.java @@ -38,6 +38,11 @@ public void marshall(AppInstanceUserMembershipSummary appInstanceUserMembershipS jsonWriter.name("ReadMarkerTimestamp"); jsonWriter.value(readMarkerTimestamp); } + if (appInstanceUserMembershipSummary.getSubChannelId() != null) { + String subChannelId = appInstanceUserMembershipSummary.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonUnmarshaller.java index 926f7a4f45..b23dab2c74 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/AppInstanceUserMembershipSummaryJsonUnmarshaller.java @@ -44,6 +44,10 @@ public AppInstanceUserMembershipSummary unmarshall(JsonUnmarshallerContext conte appInstanceUserMembershipSummary.setReadMarkerTimestamp(DateJsonUnmarshaller .getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + appInstanceUserMembershipSummary.setSubChannelId(StringJsonUnmarshaller + .getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonMarshaller.java index 65c43e0b46..e7320db33c 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonMarshaller.java @@ -53,6 +53,11 @@ public void marshall(BatchChannelMemberships batchChannelMemberships, AwsJsonWri jsonWriter.name("ChannelArn"); jsonWriter.value(channelArn); } + if (batchChannelMemberships.getSubChannelId() != null) { + String subChannelId = batchChannelMemberships.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonUnmarshaller.java index a49ee23dd8..3b76c4534d 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchChannelMembershipsJsonUnmarshaller.java @@ -50,6 +50,9 @@ public BatchChannelMemberships unmarshall(JsonUnmarshallerContext context) throw } else if (name.equals("ChannelArn")) { batchChannelMemberships.setChannelArn(StringJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + batchChannelMemberships.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchCreateChannelMembershipRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchCreateChannelMembershipRequestMarshaller.java index 28b3ac48fc..22473d1653 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchCreateChannelMembershipRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/BatchCreateChannelMembershipRequestMarshaller.java @@ -97,6 +97,11 @@ public Request marshall( } jsonWriter.endArray(); } + if (batchCreateChannelMembershipRequest.getSubChannelId() != null) { + String subChannelId = batchCreateChannelMembershipRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); jsonWriter.close(); diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonMarshaller.java index 293fc77561..ecce450cf2 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonMarshaller.java @@ -76,6 +76,13 @@ public void marshall(Channel channel, AwsJsonWriter jsonWriter) throws Exception jsonWriter.name("ChannelFlowArn"); jsonWriter.value(channelFlowArn); } + if (channel.getElasticChannelConfiguration() != null) { + ElasticChannelConfiguration elasticChannelConfiguration = channel + .getElasticChannelConfiguration(); + jsonWriter.name("ElasticChannelConfiguration"); + ElasticChannelConfigurationJsonMarshaller.getInstance().marshall( + elasticChannelConfiguration, jsonWriter); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonUnmarshaller.java index 2ab942901e..148288297b 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelJsonUnmarshaller.java @@ -65,6 +65,10 @@ public Channel unmarshall(JsonUnmarshallerContext context) throws Exception { } else if (name.equals("ChannelFlowArn")) { channel.setChannelFlowArn(StringJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("ElasticChannelConfiguration")) { + channel.setElasticChannelConfiguration(ElasticChannelConfigurationJsonUnmarshaller + .getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonMarshaller.java index 1feefc4258..2931bb0d4d 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonMarshaller.java @@ -57,6 +57,11 @@ public void marshall(ChannelMembership channelMembership, AwsJsonWriter jsonWrit jsonWriter.name("LastUpdatedTimestamp"); jsonWriter.value(lastUpdatedTimestamp); } + if (channelMembership.getSubChannelId() != null) { + String subChannelId = channelMembership.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonUnmarshaller.java index 04e942ada8..12b6bac259 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMembershipJsonUnmarshaller.java @@ -54,6 +54,9 @@ public ChannelMembership unmarshall(JsonUnmarshallerContext context) throws Exce } else if (name.equals("LastUpdatedTimestamp")) { channelMembership.setLastUpdatedTimestamp(DateJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + channelMembership.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonMarshaller.java index 255e3bfee8..0d84094b44 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonMarshaller.java @@ -65,6 +65,11 @@ public void marshall(ChannelMessageCallback channelMessageCallback, AwsJsonWrite } jsonWriter.endObject(); } + if (channelMessageCallback.getSubChannelId() != null) { + String subChannelId = channelMessageCallback.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonUnmarshaller.java index 5ee91581f0..c8a2b9581a 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageCallbackJsonUnmarshaller.java @@ -56,6 +56,9 @@ public ChannelMessageCallback unmarshall(JsonUnmarshallerContext context) throws MessageAttributeValueJsonUnmarshaller.getInstance() ) .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + channelMessageCallback.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonMarshaller.java index 577cb635dd..d38656cecd 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonMarshaller.java @@ -102,6 +102,11 @@ public void marshall(ChannelMessage channelMessage, AwsJsonWriter jsonWriter) th } jsonWriter.endObject(); } + if (channelMessage.getSubChannelId() != null) { + String subChannelId = channelMessage.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonUnmarshaller.java index 2e30393c83..d1f81939b4 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ChannelMessageJsonUnmarshaller.java @@ -78,6 +78,9 @@ public ChannelMessage unmarshall(JsonUnmarshallerContext context) throws Excepti MessageAttributeValueJsonUnmarshaller.getInstance() ) .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + channelMessage.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipRequestMarshaller.java index 65e8a6c69b..8d81033c66 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipRequestMarshaller.java @@ -88,6 +88,11 @@ public Request marshall( jsonWriter.name("Type"); jsonWriter.value(type); } + if (createChannelMembershipRequest.getSubChannelId() != null) { + String subChannelId = createChannelMembershipRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); jsonWriter.close(); diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipResultJsonUnmarshaller.java index eeef07f63c..4bfff1e8eb 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelMembershipResultJsonUnmarshaller.java @@ -40,6 +40,9 @@ public CreateChannelMembershipResult unmarshall(JsonUnmarshallerContext context) } else if (name.equals("Member")) { createChannelMembershipResult.setMember(IdentityJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + createChannelMembershipResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelRequestMarshaller.java index 23b6f5d6f7..f2a5cd6c61 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/CreateChannelRequestMarshaller.java @@ -136,6 +136,13 @@ public Request marshall(CreateChannelRequest createChannel } jsonWriter.endArray(); } + if (createChannelRequest.getElasticChannelConfiguration() != null) { + ElasticChannelConfiguration elasticChannelConfiguration = createChannelRequest + .getElasticChannelConfiguration(); + jsonWriter.name("ElasticChannelConfiguration"); + ElasticChannelConfigurationJsonMarshaller.getInstance().marshall( + elasticChannelConfiguration, jsonWriter); + } jsonWriter.endObject(); jsonWriter.close(); diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMembershipRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMembershipRequestMarshaller.java index 4d3e309d0a..50af369e4b 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMembershipRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMembershipRequestMarshaller.java @@ -69,6 +69,10 @@ public Request marshall( "{memberArn}", (deleteChannelMembershipRequest.getMemberArn() == null) ? "" : StringUtils .fromString(deleteChannelMembershipRequest.getMemberArn())); + if (deleteChannelMembershipRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(deleteChannelMembershipRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/memberships/{memberArn}"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMessageRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMessageRequestMarshaller.java index eb0f69ca83..08aa4aa91b 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMessageRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelMessageRequestMarshaller.java @@ -69,6 +69,10 @@ public Request marshall( "{messageId}", (deleteChannelMessageRequest.getMessageId() == null) ? "" : StringUtils .fromString(deleteChannelMessageRequest.getMessageId())); + if (deleteChannelMessageRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(deleteChannelMessageRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/messages/{messageId}"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelRequestMarshaller.java index 80870e37e0..6a6bf4b124 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DeleteChannelRequestMarshaller.java @@ -64,6 +64,10 @@ public Request marshall(DeleteChannelRequest deleteChannel "{channelArn}", (deleteChannelRequest.getChannelArn() == null) ? "" : StringUtils .fromString(deleteChannelRequest.getChannelArn())); + if (deleteChannelRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(deleteChannelRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DescribeChannelMembershipRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DescribeChannelMembershipRequestMarshaller.java index 1925abf840..a4d16ebf85 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DescribeChannelMembershipRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/DescribeChannelMembershipRequestMarshaller.java @@ -69,6 +69,10 @@ public Request marshall( "{memberArn}", (describeChannelMembershipRequest.getMemberArn() == null) ? "" : StringUtils .fromString(describeChannelMembershipRequest.getMemberArn())); + if (describeChannelMembershipRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(describeChannelMembershipRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/memberships/{memberArn}"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonMarshaller.java new file mode 100644 index 0000000000..5cc2b5b825 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonMarshaller.java @@ -0,0 +1,57 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.util.DateUtils; +import com.amazonaws.util.json.AwsJsonWriter; + +/** + * JSON marshaller for POJO ElasticChannelConfiguration + */ +class ElasticChannelConfigurationJsonMarshaller { + + public void marshall(ElasticChannelConfiguration elasticChannelConfiguration, + AwsJsonWriter jsonWriter) throws Exception { + jsonWriter.beginObject(); + if (elasticChannelConfiguration.getMaximumSubChannels() != null) { + Integer maximumSubChannels = elasticChannelConfiguration.getMaximumSubChannels(); + jsonWriter.name("MaximumSubChannels"); + jsonWriter.value(maximumSubChannels); + } + if (elasticChannelConfiguration.getTargetMembershipsPerSubChannel() != null) { + Integer targetMembershipsPerSubChannel = elasticChannelConfiguration + .getTargetMembershipsPerSubChannel(); + jsonWriter.name("TargetMembershipsPerSubChannel"); + jsonWriter.value(targetMembershipsPerSubChannel); + } + if (elasticChannelConfiguration.getMinimumMembershipPercentage() != null) { + Integer minimumMembershipPercentage = elasticChannelConfiguration + .getMinimumMembershipPercentage(); + jsonWriter.name("MinimumMembershipPercentage"); + jsonWriter.value(minimumMembershipPercentage); + } + jsonWriter.endObject(); + } + + private static ElasticChannelConfigurationJsonMarshaller instance; + + public static ElasticChannelConfigurationJsonMarshaller getInstance() { + if (instance == null) + instance = new ElasticChannelConfigurationJsonMarshaller(); + return instance; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonUnmarshaller.java new file mode 100644 index 0000000000..11d4209fbc --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ElasticChannelConfigurationJsonUnmarshaller.java @@ -0,0 +1,66 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.transform.SimpleTypeJsonUnmarshallers.*; +import com.amazonaws.transform.*; +import com.amazonaws.util.json.AwsJsonReader; + +/** + * JSON unmarshaller for POJO ElasticChannelConfiguration + */ +class ElasticChannelConfigurationJsonUnmarshaller implements + Unmarshaller { + + public ElasticChannelConfiguration unmarshall(JsonUnmarshallerContext context) throws Exception { + AwsJsonReader reader = context.getReader(); + if (!reader.isContainer()) { + reader.skipValue(); + return null; + } + ElasticChannelConfiguration elasticChannelConfiguration = new ElasticChannelConfiguration(); + reader.beginObject(); + while (reader.hasNext()) { + String name = reader.nextName(); + if (name.equals("MaximumSubChannels")) { + elasticChannelConfiguration.setMaximumSubChannels(IntegerJsonUnmarshaller + .getInstance() + .unmarshall(context)); + } else if (name.equals("TargetMembershipsPerSubChannel")) { + elasticChannelConfiguration + .setTargetMembershipsPerSubChannel(IntegerJsonUnmarshaller.getInstance() + .unmarshall(context)); + } else if (name.equals("MinimumMembershipPercentage")) { + elasticChannelConfiguration.setMinimumMembershipPercentage(IntegerJsonUnmarshaller + .getInstance() + .unmarshall(context)); + } else { + reader.skipValue(); + } + } + reader.endObject(); + return elasticChannelConfiguration; + } + + private static ElasticChannelConfigurationJsonUnmarshaller instance; + + public static ElasticChannelConfigurationJsonUnmarshaller getInstance() { + if (instance == null) + instance = new ElasticChannelConfigurationJsonUnmarshaller(); + return instance; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageRequestMarshaller.java index 74267c4c41..a904f0ab93 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageRequestMarshaller.java @@ -69,6 +69,10 @@ public Request marshall( "{messageId}", (getChannelMessageRequest.getMessageId() == null) ? "" : StringUtils .fromString(getChannelMessageRequest.getMessageId())); + if (getChannelMessageRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(getChannelMessageRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/messages/{messageId}"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageStatusRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageStatusRequestMarshaller.java index 20b0e8411c..bef8fcd706 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageStatusRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/GetChannelMessageStatusRequestMarshaller.java @@ -69,6 +69,10 @@ public Request marshall( "{messageId}", (getChannelMessageStatusRequest.getMessageId() == null) ? "" : StringUtils .fromString(getChannelMessageStatusRequest.getMessageId())); + if (getChannelMessageStatusRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(getChannelMessageStatusRequest.getSubChannelId())); + } request.addParameter("scope", "message-status"); request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/messages/{messageId}"; diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMembershipsRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMembershipsRequestMarshaller.java index 48a699be64..4fa0c2d49e 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMembershipsRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMembershipsRequestMarshaller.java @@ -77,6 +77,10 @@ public Request marshall( request.addParameter("next-token", StringUtils.fromString(listChannelMembershipsRequest.getNextToken())); } + if (listChannelMembershipsRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(listChannelMembershipsRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/memberships"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesRequestMarshaller.java index b51b9eefa1..2cda199935 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesRequestMarshaller.java @@ -85,6 +85,10 @@ public Request marshall( request.addParameter("next-token", StringUtils.fromString(listChannelMessagesRequest.getNextToken())); } + if (listChannelMessagesRequest.getSubChannelId() != null) { + request.addParameter("sub-channel-id", + StringUtils.fromString(listChannelMessagesRequest.getSubChannelId())); + } request.setResourcePath(uriResourcePath); String encodedUriResourcePath = "/channels/{channelArn}/messages"; encodedUriResourcePath = encodedUriResourcePath.replace( diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesResultJsonUnmarshaller.java index 5bdecf4223..0db3af4990 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListChannelMessagesResultJsonUnmarshaller.java @@ -45,6 +45,9 @@ public ListChannelMessagesResult unmarshall(JsonUnmarshallerContext context) thr ChannelMessageSummaryJsonUnmarshaller.getInstance() ) .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + listChannelMessagesResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsRequestMarshaller.java new file mode 100644 index 0000000000..d904a6677e --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsRequestMarshaller.java @@ -0,0 +1,88 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import static com.amazonaws.util.StringUtils.UTF8; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.OutputStreamWriter; +import java.io.StringWriter; +import java.io.Writer; + +import android.text.TextUtils; + +import com.amazonaws.AmazonClientException; +import com.amazonaws.Request; +import com.amazonaws.DefaultRequest; +import com.amazonaws.http.HttpMethodName; +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.transform.Marshaller; +import com.amazonaws.util.BinaryUtils; +import com.amazonaws.util.DateUtils; +import com.amazonaws.util.StringUtils; +import com.amazonaws.util.StringInputStream; +import com.amazonaws.util.json.AwsJsonWriter; +import com.amazonaws.util.json.JsonUtils; + +import android.net.Uri; + +/** + * JSON request marshaller for ListSubChannelsRequest + */ +public class ListSubChannelsRequestMarshaller implements + Marshaller, ListSubChannelsRequest> { + + public Request marshall(ListSubChannelsRequest listSubChannelsRequest) { + if (listSubChannelsRequest == null) { + throw new AmazonClientException( + "Invalid argument passed to marshall(ListSubChannelsRequest)"); + } + + Request request = new DefaultRequest( + listSubChannelsRequest, "AmazonChimeSDKMessaging"); + request.setHttpMethod(HttpMethodName.GET); + + if (listSubChannelsRequest.getChimeBearer() != null) { + request.addHeader("x-amz-chime-bearer", + StringUtils.fromString(listSubChannelsRequest.getChimeBearer())); + } + String uriResourcePath = "/channels/{channelArn}/subchannels"; + uriResourcePath = uriResourcePath.replace( + "{channelArn}", + (listSubChannelsRequest.getChannelArn() == null) ? "" : StringUtils + .fromString(listSubChannelsRequest.getChannelArn())); + if (listSubChannelsRequest.getMaxResults() != null) { + request.addParameter("max-results", + StringUtils.fromInteger(listSubChannelsRequest.getMaxResults())); + } + if (listSubChannelsRequest.getNextToken() != null) { + request.addParameter("next-token", + StringUtils.fromString(listSubChannelsRequest.getNextToken())); + } + request.setResourcePath(uriResourcePath); + String encodedUriResourcePath = "/channels/{channelArn}/subchannels"; + encodedUriResourcePath = encodedUriResourcePath.replace( + "{channelArn}", + (listSubChannelsRequest.getChannelArn() == null) ? "" : Uri.encode(StringUtils + .fromString(listSubChannelsRequest.getChannelArn()))); + request.setEncodedResourcePath(encodedUriResourcePath); + if (!request.getHeaders().containsKey("Content-Type")) { + request.addHeader("Content-Type", "application/x-amz-json-1.0"); + } + + return request; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsResultJsonUnmarshaller.java new file mode 100644 index 0000000000..347e261d08 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/ListSubChannelsResultJsonUnmarshaller.java @@ -0,0 +1,63 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.transform.SimpleTypeJsonUnmarshallers.*; +import com.amazonaws.transform.*; +import com.amazonaws.util.json.AwsJsonReader; + +/** + * JSON unmarshaller for response ListSubChannelsResult + */ +public class ListSubChannelsResultJsonUnmarshaller implements + Unmarshaller { + + public ListSubChannelsResult unmarshall(JsonUnmarshallerContext context) throws Exception { + ListSubChannelsResult listSubChannelsResult = new ListSubChannelsResult(); + + AwsJsonReader reader = context.getReader(); + reader.beginObject(); + while (reader.hasNext()) { + String name = reader.nextName(); + if (name.equals("ChannelArn")) { + listSubChannelsResult.setChannelArn(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); + } else if (name.equals("SubChannels")) { + listSubChannelsResult.setSubChannels(new ListUnmarshaller( + SubChannelSummaryJsonUnmarshaller.getInstance() + ) + .unmarshall(context)); + } else if (name.equals("NextToken")) { + listSubChannelsResult.setNextToken(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); + } else { + reader.skipValue(); + } + } + reader.endObject(); + + return listSubChannelsResult; + } + + private static ListSubChannelsResultJsonUnmarshaller instance; + + public static ListSubChannelsResultJsonUnmarshaller getInstance() { + if (instance == null) + instance = new ListSubChannelsResultJsonUnmarshaller(); + return instance; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageRequestMarshaller.java index 4686dfbb2a..2d6509a095 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageRequestMarshaller.java @@ -81,8 +81,27 @@ public Request marshall( (redactChannelMessageRequest.getMessageId() == null) ? "" : Uri.encode(StringUtils .fromString(redactChannelMessageRequest.getMessageId()))); request.setEncodedResourcePath(encodedUriResourcePath); - request.addHeader("Content-Length", "0"); - request.setContent(new ByteArrayInputStream(new byte[0])); + try { + StringWriter stringWriter = new StringWriter(); + AwsJsonWriter jsonWriter = JsonUtils.getJsonWriter(stringWriter); + jsonWriter.beginObject(); + + if (redactChannelMessageRequest.getSubChannelId() != null) { + String subChannelId = redactChannelMessageRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } + + jsonWriter.endObject(); + jsonWriter.close(); + String snippet = stringWriter.toString(); + byte[] content = snippet.getBytes(UTF8); + request.setContent(new StringInputStream(snippet)); + request.addHeader("Content-Length", Integer.toString(content.length)); + } catch (Throwable t) { + throw new AmazonClientException( + "Unable to marshall request to JSON: " + t.getMessage(), t); + } if (!request.getHeaders().containsKey("Content-Type")) { request.addHeader("Content-Type", "application/x-amz-json-1.0"); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageResultJsonUnmarshaller.java index 88a2d08b0b..4458f62895 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/RedactChannelMessageResultJsonUnmarshaller.java @@ -39,6 +39,9 @@ public RedactChannelMessageResult unmarshall(JsonUnmarshallerContext context) th } else if (name.equals("MessageId")) { redactChannelMessageResult.setMessageId(StringJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + redactChannelMessageResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageRequestMarshaller.java index 5b732a27ae..0b9be7ee89 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageRequestMarshaller.java @@ -126,6 +126,11 @@ public Request marshall( } jsonWriter.endObject(); } + if (sendChannelMessageRequest.getSubChannelId() != null) { + String subChannelId = sendChannelMessageRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); jsonWriter.close(); diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageResultJsonUnmarshaller.java index acd8188fce..c1f6a95d1f 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SendChannelMessageResultJsonUnmarshaller.java @@ -43,6 +43,9 @@ public SendChannelMessageResult unmarshall(JsonUnmarshallerContext context) thro sendChannelMessageResult.setStatus(ChannelMessageStatusStructureJsonUnmarshaller .getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + sendChannelMessageResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonMarshaller.java new file mode 100644 index 0000000000..5edb04f8d4 --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonMarshaller.java @@ -0,0 +1,50 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.util.DateUtils; +import com.amazonaws.util.json.AwsJsonWriter; + +/** + * JSON marshaller for POJO SubChannelSummary + */ +class SubChannelSummaryJsonMarshaller { + + public void marshall(SubChannelSummary subChannelSummary, AwsJsonWriter jsonWriter) + throws Exception { + jsonWriter.beginObject(); + if (subChannelSummary.getSubChannelId() != null) { + String subChannelId = subChannelSummary.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } + if (subChannelSummary.getMembershipCount() != null) { + Integer membershipCount = subChannelSummary.getMembershipCount(); + jsonWriter.name("MembershipCount"); + jsonWriter.value(membershipCount); + } + jsonWriter.endObject(); + } + + private static SubChannelSummaryJsonMarshaller instance; + + public static SubChannelSummaryJsonMarshaller getInstance() { + if (instance == null) + instance = new SubChannelSummaryJsonMarshaller(); + return instance; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonUnmarshaller.java new file mode 100644 index 0000000000..1833a8935d --- /dev/null +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/SubChannelSummaryJsonUnmarshaller.java @@ -0,0 +1,60 @@ +/* + * Copyright 2010-2022 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.chimesdkmessaging.model.transform; + +import com.amazonaws.services.chimesdkmessaging.model.*; +import com.amazonaws.transform.SimpleTypeJsonUnmarshallers.*; +import com.amazonaws.transform.*; +import com.amazonaws.util.json.AwsJsonReader; + +/** + * JSON unmarshaller for POJO SubChannelSummary + */ +class SubChannelSummaryJsonUnmarshaller implements + Unmarshaller { + + public SubChannelSummary unmarshall(JsonUnmarshallerContext context) throws Exception { + AwsJsonReader reader = context.getReader(); + if (!reader.isContainer()) { + reader.skipValue(); + return null; + } + SubChannelSummary subChannelSummary = new SubChannelSummary(); + reader.beginObject(); + while (reader.hasNext()) { + String name = reader.nextName(); + if (name.equals("SubChannelId")) { + subChannelSummary.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); + } else if (name.equals("MembershipCount")) { + subChannelSummary.setMembershipCount(IntegerJsonUnmarshaller.getInstance() + .unmarshall(context)); + } else { + reader.skipValue(); + } + } + reader.endObject(); + return subChannelSummary; + } + + private static SubChannelSummaryJsonUnmarshaller instance; + + public static SubChannelSummaryJsonUnmarshaller getInstance() { + if (instance == null) + instance = new SubChannelSummaryJsonUnmarshaller(); + return instance; + } +} diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageRequestMarshaller.java index 5f8a846b0a..efa08e61f0 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageRequestMarshaller.java @@ -95,6 +95,11 @@ public Request marshall( jsonWriter.name("Metadata"); jsonWriter.value(metadata); } + if (updateChannelMessageRequest.getSubChannelId() != null) { + String subChannelId = updateChannelMessageRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } jsonWriter.endObject(); jsonWriter.close(); diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageResultJsonUnmarshaller.java index 4a4ec95b63..a0a60d2c62 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelMessageResultJsonUnmarshaller.java @@ -43,6 +43,9 @@ public UpdateChannelMessageResult unmarshall(JsonUnmarshallerContext context) th updateChannelMessageResult.setStatus(ChannelMessageStatusStructureJsonUnmarshaller .getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + updateChannelMessageResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerRequestMarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerRequestMarshaller.java index 75739ae4c8..060fb13bb3 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerRequestMarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerRequestMarshaller.java @@ -73,8 +73,27 @@ public Request marshall( .encode(StringUtils.fromString(updateChannelReadMarkerRequest .getChannelArn()))); request.setEncodedResourcePath(encodedUriResourcePath); - request.addHeader("Content-Length", "0"); - request.setContent(new ByteArrayInputStream(new byte[0])); + try { + StringWriter stringWriter = new StringWriter(); + AwsJsonWriter jsonWriter = JsonUtils.getJsonWriter(stringWriter); + jsonWriter.beginObject(); + + if (updateChannelReadMarkerRequest.getSubChannelId() != null) { + String subChannelId = updateChannelReadMarkerRequest.getSubChannelId(); + jsonWriter.name("SubChannelId"); + jsonWriter.value(subChannelId); + } + + jsonWriter.endObject(); + jsonWriter.close(); + String snippet = stringWriter.toString(); + byte[] content = snippet.getBytes(UTF8); + request.setContent(new StringInputStream(snippet)); + request.addHeader("Content-Length", Integer.toString(content.length)); + } catch (Throwable t) { + throw new AmazonClientException( + "Unable to marshall request to JSON: " + t.getMessage(), t); + } if (!request.getHeaders().containsKey("Content-Type")) { request.addHeader("Content-Type", "application/x-amz-json-1.0"); } diff --git a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerResultJsonUnmarshaller.java b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerResultJsonUnmarshaller.java index 9f49cf2bb3..87f7f94679 100644 --- a/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerResultJsonUnmarshaller.java +++ b/aws-android-sdk-chimesdkmessaging/src/main/java/com/amazonaws/services/chimesdkmessaging/model/transform/UpdateChannelReadMarkerResultJsonUnmarshaller.java @@ -37,6 +37,9 @@ public UpdateChannelReadMarkerResult unmarshall(JsonUnmarshallerContext context) if (name.equals("ChannelArn")) { updateChannelReadMarkerResult.setChannelArn(StringJsonUnmarshaller.getInstance() .unmarshall(context)); + } else if (name.equals("SubChannelId")) { + updateChannelReadMarkerResult.setSubChannelId(StringJsonUnmarshaller.getInstance() + .unmarshall(context)); } else { reader.skipValue(); }