/* * 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.iotfleetwise.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 UpdateDecoderManifestRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The name of the decoder manifest to update. *
*/ private String name; /** ** A brief description of the decoder manifest to update. *
*/ private String description; /** ** A list of information about decoding additional signals to add to the decoder manifest. *
*/ private java.util.List* A list of updated information about decoding signals to update in the decoder manifest. *
*/ private java.util.List* A list of signal decoders to remove from the decoder manifest. *
*/ private java.util.List* A list of information about the network interfaces to add to the decoder manifest. *
*/ private java.util.List* A list of information about the network interfaces to update in the decoder manifest. *
*/ private java.util.List* A list of network interfaces to remove from the decoder manifest. *
*/ private java.util.List
* The state of the decoder manifest. If the status is ACTIVE
, the decoder manifest can't be edited. If
* the status is DRAFT
, you can edit the decoder manifest.
*
* The name of the decoder manifest to update. *
* * @param name * The name of the decoder manifest to update. */ public void setName(String name) { this.name = name; } /** ** The name of the decoder manifest to update. *
* * @return The name of the decoder manifest to update. */ public String getName() { return this.name; } /** ** The name of the decoder manifest to update. *
* * @param name * The name of the decoder manifest to update. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withName(String name) { setName(name); return this; } /** ** A brief description of the decoder manifest to update. *
* * @param description * A brief description of the decoder manifest to update. */ public void setDescription(String description) { this.description = description; } /** ** A brief description of the decoder manifest to update. *
* * @return A brief description of the decoder manifest to update. */ public String getDescription() { return this.description; } /** ** A brief description of the decoder manifest to update. *
* * @param description * A brief description of the decoder manifest to update. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withDescription(String description) { setDescription(description); return this; } /** ** A list of information about decoding additional signals to add to the decoder manifest. *
* * @return A list of information about decoding additional signals to add to the decoder manifest. */ public java.util.List* A list of information about decoding additional signals to add to the decoder manifest. *
* * @param signalDecodersToAdd * A list of information about decoding additional signals to add to the decoder manifest. */ public void setSignalDecodersToAdd(java.util.Collection* A list of information about decoding additional signals to add to the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSignalDecodersToAdd(java.util.Collection)} or {@link #withSignalDecodersToAdd(java.util.Collection)} * if you want to override the existing values. *
* * @param signalDecodersToAdd * A list of information about decoding additional signals to add to the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToAdd(SignalDecoder... signalDecodersToAdd) { if (this.signalDecodersToAdd == null) { setSignalDecodersToAdd(new java.util.ArrayList* A list of information about decoding additional signals to add to the decoder manifest. *
* * @param signalDecodersToAdd * A list of information about decoding additional signals to add to the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToAdd(java.util.Collection* A list of updated information about decoding signals to update in the decoder manifest. *
* * @return A list of updated information about decoding signals to update in the decoder manifest. */ public java.util.List* A list of updated information about decoding signals to update in the decoder manifest. *
* * @param signalDecodersToUpdate * A list of updated information about decoding signals to update in the decoder manifest. */ public void setSignalDecodersToUpdate(java.util.Collection* A list of updated information about decoding signals to update in the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSignalDecodersToUpdate(java.util.Collection)} or * {@link #withSignalDecodersToUpdate(java.util.Collection)} if you want to override the existing values. *
* * @param signalDecodersToUpdate * A list of updated information about decoding signals to update in the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToUpdate(SignalDecoder... signalDecodersToUpdate) { if (this.signalDecodersToUpdate == null) { setSignalDecodersToUpdate(new java.util.ArrayList* A list of updated information about decoding signals to update in the decoder manifest. *
* * @param signalDecodersToUpdate * A list of updated information about decoding signals to update in the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToUpdate(java.util.Collection* A list of signal decoders to remove from the decoder manifest. *
* * @return A list of signal decoders to remove from the decoder manifest. */ public java.util.List* A list of signal decoders to remove from the decoder manifest. *
* * @param signalDecodersToRemove * A list of signal decoders to remove from the decoder manifest. */ public void setSignalDecodersToRemove(java.util.Collection* A list of signal decoders to remove from the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setSignalDecodersToRemove(java.util.Collection)} or * {@link #withSignalDecodersToRemove(java.util.Collection)} if you want to override the existing values. *
* * @param signalDecodersToRemove * A list of signal decoders to remove from the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToRemove(String... signalDecodersToRemove) { if (this.signalDecodersToRemove == null) { setSignalDecodersToRemove(new java.util.ArrayList* A list of signal decoders to remove from the decoder manifest. *
* * @param signalDecodersToRemove * A list of signal decoders to remove from the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withSignalDecodersToRemove(java.util.Collection* A list of information about the network interfaces to add to the decoder manifest. *
* * @return A list of information about the network interfaces to add to the decoder manifest. */ public java.util.List* A list of information about the network interfaces to add to the decoder manifest. *
* * @param networkInterfacesToAdd * A list of information about the network interfaces to add to the decoder manifest. */ public void setNetworkInterfacesToAdd(java.util.Collection* A list of information about the network interfaces to add to the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setNetworkInterfacesToAdd(java.util.Collection)} or * {@link #withNetworkInterfacesToAdd(java.util.Collection)} if you want to override the existing values. *
* * @param networkInterfacesToAdd * A list of information about the network interfaces to add to the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToAdd(NetworkInterface... networkInterfacesToAdd) { if (this.networkInterfacesToAdd == null) { setNetworkInterfacesToAdd(new java.util.ArrayList* A list of information about the network interfaces to add to the decoder manifest. *
* * @param networkInterfacesToAdd * A list of information about the network interfaces to add to the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToAdd(java.util.Collection* A list of information about the network interfaces to update in the decoder manifest. *
* * @return A list of information about the network interfaces to update in the decoder manifest. */ public java.util.List* A list of information about the network interfaces to update in the decoder manifest. *
* * @param networkInterfacesToUpdate * A list of information about the network interfaces to update in the decoder manifest. */ public void setNetworkInterfacesToUpdate(java.util.Collection* A list of information about the network interfaces to update in the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setNetworkInterfacesToUpdate(java.util.Collection)} or * {@link #withNetworkInterfacesToUpdate(java.util.Collection)} if you want to override the existing values. *
* * @param networkInterfacesToUpdate * A list of information about the network interfaces to update in the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToUpdate(NetworkInterface... networkInterfacesToUpdate) { if (this.networkInterfacesToUpdate == null) { setNetworkInterfacesToUpdate(new java.util.ArrayList* A list of information about the network interfaces to update in the decoder manifest. *
* * @param networkInterfacesToUpdate * A list of information about the network interfaces to update in the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToUpdate(java.util.Collection* A list of network interfaces to remove from the decoder manifest. *
* * @return A list of network interfaces to remove from the decoder manifest. */ public java.util.List* A list of network interfaces to remove from the decoder manifest. *
* * @param networkInterfacesToRemove * A list of network interfaces to remove from the decoder manifest. */ public void setNetworkInterfacesToRemove(java.util.Collection* A list of network interfaces to remove from the decoder manifest. *
** NOTE: This method appends the values to the existing list (if any). Use * {@link #setNetworkInterfacesToRemove(java.util.Collection)} or * {@link #withNetworkInterfacesToRemove(java.util.Collection)} if you want to override the existing values. *
* * @param networkInterfacesToRemove * A list of network interfaces to remove from the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToRemove(String... networkInterfacesToRemove) { if (this.networkInterfacesToRemove == null) { setNetworkInterfacesToRemove(new java.util.ArrayList* A list of network interfaces to remove from the decoder manifest. *
* * @param networkInterfacesToRemove * A list of network interfaces to remove from the decoder manifest. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateDecoderManifestRequest withNetworkInterfacesToRemove(java.util.Collection
* The state of the decoder manifest. If the status is ACTIVE
, the decoder manifest can't be edited. If
* the status is DRAFT
, you can edit the decoder manifest.
*
ACTIVE
, the decoder manifest can't be
* edited. If the status is DRAFT
, you can edit the decoder manifest.
* @see ManifestStatus
*/
public void setStatus(String status) {
this.status = status;
}
/**
*
* The state of the decoder manifest. If the status is ACTIVE
, the decoder manifest can't be edited. If
* the status is DRAFT
, you can edit the decoder manifest.
*
ACTIVE
, the decoder manifest can't be
* edited. If the status is DRAFT
, you can edit the decoder manifest.
* @see ManifestStatus
*/
public String getStatus() {
return this.status;
}
/**
*
* The state of the decoder manifest. If the status is ACTIVE
, the decoder manifest can't be edited. If
* the status is DRAFT
, you can edit the decoder manifest.
*
ACTIVE
, the decoder manifest can't be
* edited. If the status is DRAFT
, you can edit the decoder manifest.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ManifestStatus
*/
public UpdateDecoderManifestRequest withStatus(String status) {
setStatus(status);
return this;
}
/**
*
* The state of the decoder manifest. If the status is ACTIVE
, the decoder manifest can't be edited. If
* the status is DRAFT
, you can edit the decoder manifest.
*
ACTIVE
, the decoder manifest can't be
* edited. If the status is DRAFT
, you can edit the decoder manifest.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ManifestStatus
*/
public UpdateDecoderManifestRequest withStatus(ManifestStatus status) {
this.status = status.toString();
return this;
}
/**
* Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be
* redacted from this string using a placeholder value.
*
* @return A string representation of this object.
*
* @see java.lang.Object#toString()
*/
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("{");
if (getName() != null)
sb.append("Name: ").append(getName()).append(",");
if (getDescription() != null)
sb.append("Description: ").append(getDescription()).append(",");
if (getSignalDecodersToAdd() != null)
sb.append("SignalDecodersToAdd: ").append(getSignalDecodersToAdd()).append(",");
if (getSignalDecodersToUpdate() != null)
sb.append("SignalDecodersToUpdate: ").append(getSignalDecodersToUpdate()).append(",");
if (getSignalDecodersToRemove() != null)
sb.append("SignalDecodersToRemove: ").append(getSignalDecodersToRemove()).append(",");
if (getNetworkInterfacesToAdd() != null)
sb.append("NetworkInterfacesToAdd: ").append(getNetworkInterfacesToAdd()).append(",");
if (getNetworkInterfacesToUpdate() != null)
sb.append("NetworkInterfacesToUpdate: ").append(getNetworkInterfacesToUpdate()).append(",");
if (getNetworkInterfacesToRemove() != null)
sb.append("NetworkInterfacesToRemove: ").append(getNetworkInterfacesToRemove()).append(",");
if (getStatus() != null)
sb.append("Status: ").append(getStatus());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof UpdateDecoderManifestRequest == false)
return false;
UpdateDecoderManifestRequest other = (UpdateDecoderManifestRequest) obj;
if (other.getName() == null ^ this.getName() == null)
return false;
if (other.getName() != null && other.getName().equals(this.getName()) == false)
return false;
if (other.getDescription() == null ^ this.getDescription() == null)
return false;
if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false)
return false;
if (other.getSignalDecodersToAdd() == null ^ this.getSignalDecodersToAdd() == null)
return false;
if (other.getSignalDecodersToAdd() != null && other.getSignalDecodersToAdd().equals(this.getSignalDecodersToAdd()) == false)
return false;
if (other.getSignalDecodersToUpdate() == null ^ this.getSignalDecodersToUpdate() == null)
return false;
if (other.getSignalDecodersToUpdate() != null && other.getSignalDecodersToUpdate().equals(this.getSignalDecodersToUpdate()) == false)
return false;
if (other.getSignalDecodersToRemove() == null ^ this.getSignalDecodersToRemove() == null)
return false;
if (other.getSignalDecodersToRemove() != null && other.getSignalDecodersToRemove().equals(this.getSignalDecodersToRemove()) == false)
return false;
if (other.getNetworkInterfacesToAdd() == null ^ this.getNetworkInterfacesToAdd() == null)
return false;
if (other.getNetworkInterfacesToAdd() != null && other.getNetworkInterfacesToAdd().equals(this.getNetworkInterfacesToAdd()) == false)
return false;
if (other.getNetworkInterfacesToUpdate() == null ^ this.getNetworkInterfacesToUpdate() == null)
return false;
if (other.getNetworkInterfacesToUpdate() != null && other.getNetworkInterfacesToUpdate().equals(this.getNetworkInterfacesToUpdate()) == false)
return false;
if (other.getNetworkInterfacesToRemove() == null ^ this.getNetworkInterfacesToRemove() == null)
return false;
if (other.getNetworkInterfacesToRemove() != null && other.getNetworkInterfacesToRemove().equals(this.getNetworkInterfacesToRemove()) == false)
return false;
if (other.getStatus() == null ^ this.getStatus() == null)
return false;
if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode());
hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode());
hashCode = prime * hashCode + ((getSignalDecodersToAdd() == null) ? 0 : getSignalDecodersToAdd().hashCode());
hashCode = prime * hashCode + ((getSignalDecodersToUpdate() == null) ? 0 : getSignalDecodersToUpdate().hashCode());
hashCode = prime * hashCode + ((getSignalDecodersToRemove() == null) ? 0 : getSignalDecodersToRemove().hashCode());
hashCode = prime * hashCode + ((getNetworkInterfacesToAdd() == null) ? 0 : getNetworkInterfacesToAdd().hashCode());
hashCode = prime * hashCode + ((getNetworkInterfacesToUpdate() == null) ? 0 : getNetworkInterfacesToUpdate().hashCode());
hashCode = prime * hashCode + ((getNetworkInterfacesToRemove() == null) ? 0 : getNetworkInterfacesToRemove().hashCode());
hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode());
return hashCode;
}
@Override
public UpdateDecoderManifestRequest clone() {
return (UpdateDecoderManifestRequest) super.clone();
}
}