/* * Copyright 2018-2023 Amazon.com, Inc. or its affiliates. All Rights Reserved. * * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with * the License. A copy of the License is located at * * http://aws.amazon.com/apache2.0 * * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions * and limitations under the License. */ package com.amazonaws.services.iotanalytics.model; import java.io.Serializable; import javax.annotation.Generated; import com.amazonaws.AmazonWebServiceRequest; /** * * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class CreateChannelRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The name of the channel. *
*/ private String channelName; /** *
* Where channel data is stored. You can choose one of serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
. You can't
* change this storage option after the channel is created.
*
* How long, in days, message data is kept for the channel. When customerManagedS3
storage is selected,
* this parameter is ignored.
*
* Metadata which can be used to manage the channel. *
*/ private java.util.List* The name of the channel. *
* * @param channelName * The name of the channel. */ public void setChannelName(String channelName) { this.channelName = channelName; } /** ** The name of the channel. *
* * @return The name of the channel. */ public String getChannelName() { return this.channelName; } /** ** The name of the channel. *
* * @param channelName * The name of the channel. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateChannelRequest withChannelName(String channelName) { setChannelName(channelName); return this; } /** *
* Where channel data is stored. You can choose one of serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
. You can't
* change this storage option after the channel is created.
*
serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
.
* You can't change this storage option after the channel is created.
*/
public void setChannelStorage(ChannelStorage channelStorage) {
this.channelStorage = channelStorage;
}
/**
*
* Where channel data is stored. You can choose one of serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
. You can't
* change this storage option after the channel is created.
*
serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
.
* You can't change this storage option after the channel is created.
*/
public ChannelStorage getChannelStorage() {
return this.channelStorage;
}
/**
*
* Where channel data is stored. You can choose one of serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
. You can't
* change this storage option after the channel is created.
*
serviceManagedS3
or
* customerManagedS3
storage. If not specified, the default is serviceManagedS3
.
* You can't change this storage option after the channel is created.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateChannelRequest withChannelStorage(ChannelStorage channelStorage) {
setChannelStorage(channelStorage);
return this;
}
/**
*
* How long, in days, message data is kept for the channel. When customerManagedS3
storage is selected,
* this parameter is ignored.
*
customerManagedS3
storage is
* selected, this parameter is ignored.
*/
public void setRetentionPeriod(RetentionPeriod retentionPeriod) {
this.retentionPeriod = retentionPeriod;
}
/**
*
* How long, in days, message data is kept for the channel. When customerManagedS3
storage is selected,
* this parameter is ignored.
*
customerManagedS3
storage is
* selected, this parameter is ignored.
*/
public RetentionPeriod getRetentionPeriod() {
return this.retentionPeriod;
}
/**
*
* How long, in days, message data is kept for the channel. When customerManagedS3
storage is selected,
* this parameter is ignored.
*
customerManagedS3
storage is
* selected, this parameter is ignored.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public CreateChannelRequest withRetentionPeriod(RetentionPeriod retentionPeriod) {
setRetentionPeriod(retentionPeriod);
return this;
}
/**
* * Metadata which can be used to manage the channel. *
* * @return Metadata which can be used to manage the channel. */ public java.util.List* Metadata which can be used to manage the channel. *
* * @param tags * Metadata which can be used to manage the channel. */ public void setTags(java.util.Collection* Metadata which can be used to manage the channel. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setTags(java.util.Collection)} or {@link #withTags(java.util.Collection)} if you want to override the * existing values. *
* * @param tags * Metadata which can be used to manage the channel. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateChannelRequest withTags(Tag... tags) { if (this.tags == null) { setTags(new java.util.ArrayList* Metadata which can be used to manage the channel. *
* * @param tags * Metadata which can be used to manage the channel. * @return Returns a reference to this object so that method calls can be chained together. */ public CreateChannelRequest withTags(java.util.Collection