/* * 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.snowball.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 UpdateJobShipmentStateRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The job ID of the job whose shipment date you want to update, for example
* JID123e4567-e89b-12d3-a456-426655440000
.
*
* The state of a device when it is being shipped. *
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
*
* The job ID of the job whose shipment date you want to update, for example
* JID123e4567-e89b-12d3-a456-426655440000
.
*
JID123e4567-e89b-12d3-a456-426655440000
.
*/
public void setJobId(String jobId) {
this.jobId = jobId;
}
/**
*
* The job ID of the job whose shipment date you want to update, for example
* JID123e4567-e89b-12d3-a456-426655440000
.
*
JID123e4567-e89b-12d3-a456-426655440000
.
*/
public String getJobId() {
return this.jobId;
}
/**
*
* The job ID of the job whose shipment date you want to update, for example
* JID123e4567-e89b-12d3-a456-426655440000
.
*
JID123e4567-e89b-12d3-a456-426655440000
.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public UpdateJobShipmentStateRequest withJobId(String jobId) {
setJobId(jobId);
return this;
}
/**
* * The state of a device when it is being shipped. *
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
* @see ShipmentState
*/
public void setShipmentState(String shipmentState) {
this.shipmentState = shipmentState;
}
/**
*
* The state of a device when it is being shipped. *
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
* @see ShipmentState
*/
public String getShipmentState() {
return this.shipmentState;
}
/**
*
* The state of a device when it is being shipped. *
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ShipmentState
*/
public UpdateJobShipmentStateRequest withShipmentState(String shipmentState) {
setShipmentState(shipmentState);
return this;
}
/**
*
* The state of a device when it is being shipped. *
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
*
* Set to RECEIVED
when the device arrives at your location.
*
* Set to RETURNED
when you have returned the device to Amazon Web Services.
* @return Returns a reference to this object so that method calls can be chained together.
* @see ShipmentState
*/
public UpdateJobShipmentStateRequest withShipmentState(ShipmentState shipmentState) {
this.shipmentState = shipmentState.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 (getJobId() != null)
sb.append("JobId: ").append(getJobId()).append(",");
if (getShipmentState() != null)
sb.append("ShipmentState: ").append(getShipmentState());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof UpdateJobShipmentStateRequest == false)
return false;
UpdateJobShipmentStateRequest other = (UpdateJobShipmentStateRequest) obj;
if (other.getJobId() == null ^ this.getJobId() == null)
return false;
if (other.getJobId() != null && other.getJobId().equals(this.getJobId()) == false)
return false;
if (other.getShipmentState() == null ^ this.getShipmentState() == null)
return false;
if (other.getShipmentState() != null && other.getShipmentState().equals(this.getShipmentState()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getJobId() == null) ? 0 : getJobId().hashCode());
hashCode = prime * hashCode + ((getShipmentState() == null) ? 0 : getShipmentState().hashCode());
return hashCode;
}
@Override
public UpdateJobShipmentStateRequest clone() {
return (UpdateJobShipmentStateRequest) super.clone();
}
}