/* * 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.iotjobsdataplane.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 StartNextPendingJobExecutionRequest extends com.amazonaws.AmazonWebServiceRequest implements Serializable, Cloneable { /** *
* The name of the thing associated with the device. *
*/ private String thingName; /** ** A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. *
*/ private java.util.Map
* Specifies the amount of time this device has to finish execution of this job. If the job execution status is not
* set to a terminal state before this timer expires, or before the timer is reset (by calling
* UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new timeout
* value in field stepTimeoutInMinutes
) the job execution status will be automatically set to
* TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout which may have
* been specified when the job was created (CreateJob
using field timeoutConfig
).
*
* The name of the thing associated with the device. *
* * @param thingName * The name of the thing associated with the device. */ public void setThingName(String thingName) { this.thingName = thingName; } /** ** The name of the thing associated with the device. *
* * @return The name of the thing associated with the device. */ public String getThingName() { return this.thingName; } /** ** The name of the thing associated with the device. *
* * @param thingName * The name of the thing associated with the device. * @return Returns a reference to this object so that method calls can be chained together. */ public StartNextPendingJobExecutionRequest withThingName(String thingName) { setThingName(thingName); return this; } /** ** A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. *
* * @return A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. */ public java.util.Map* A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. *
* * @param statusDetails * A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. */ public void setStatusDetails(java.util.Map* A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. *
* * @param statusDetails * A collection of name/value pairs that describe the status of the job execution. If not specified, the * statusDetails are unchanged. * @return Returns a reference to this object so that method calls can be chained together. */ public StartNextPendingJobExecutionRequest withStatusDetails(java.util.Map
* Specifies the amount of time this device has to finish execution of this job. If the job execution status is not
* set to a terminal state before this timer expires, or before the timer is reset (by calling
* UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new timeout
* value in field stepTimeoutInMinutes
) the job execution status will be automatically set to
* TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout which may have
* been specified when the job was created (CreateJob
using field timeoutConfig
).
*
UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new
* timeout value in field stepTimeoutInMinutes
) the job execution status will be automatically
* set to TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout
* which may have been specified when the job was created (CreateJob
using field
* timeoutConfig
).
*/
public void setStepTimeoutInMinutes(Long stepTimeoutInMinutes) {
this.stepTimeoutInMinutes = stepTimeoutInMinutes;
}
/**
*
* Specifies the amount of time this device has to finish execution of this job. If the job execution status is not
* set to a terminal state before this timer expires, or before the timer is reset (by calling
* UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new timeout
* value in field stepTimeoutInMinutes
) the job execution status will be automatically set to
* TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout which may have
* been specified when the job was created (CreateJob
using field timeoutConfig
).
*
UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new
* timeout value in field stepTimeoutInMinutes
) the job execution status will be automatically
* set to TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout
* which may have been specified when the job was created (CreateJob
using field
* timeoutConfig
).
*/
public Long getStepTimeoutInMinutes() {
return this.stepTimeoutInMinutes;
}
/**
*
* Specifies the amount of time this device has to finish execution of this job. If the job execution status is not
* set to a terminal state before this timer expires, or before the timer is reset (by calling
* UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new timeout
* value in field stepTimeoutInMinutes
) the job execution status will be automatically set to
* TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout which may have
* been specified when the job was created (CreateJob
using field timeoutConfig
).
*
UpdateJobExecution
, setting the status to IN_PROGRESS
and specifying a new
* timeout value in field stepTimeoutInMinutes
) the job execution status will be automatically
* set to TIMED_OUT
. Note that setting this timeout has no effect on that job execution timeout
* which may have been specified when the job was created (CreateJob
using field
* timeoutConfig
).
* @return Returns a reference to this object so that method calls can be chained together.
*/
public StartNextPendingJobExecutionRequest withStepTimeoutInMinutes(Long stepTimeoutInMinutes) {
setStepTimeoutInMinutes(stepTimeoutInMinutes);
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 (getThingName() != null)
sb.append("ThingName: ").append(getThingName()).append(",");
if (getStatusDetails() != null)
sb.append("StatusDetails: ").append(getStatusDetails()).append(",");
if (getStepTimeoutInMinutes() != null)
sb.append("StepTimeoutInMinutes: ").append(getStepTimeoutInMinutes());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof StartNextPendingJobExecutionRequest == false)
return false;
StartNextPendingJobExecutionRequest other = (StartNextPendingJobExecutionRequest) obj;
if (other.getThingName() == null ^ this.getThingName() == null)
return false;
if (other.getThingName() != null && other.getThingName().equals(this.getThingName()) == false)
return false;
if (other.getStatusDetails() == null ^ this.getStatusDetails() == null)
return false;
if (other.getStatusDetails() != null && other.getStatusDetails().equals(this.getStatusDetails()) == false)
return false;
if (other.getStepTimeoutInMinutes() == null ^ this.getStepTimeoutInMinutes() == null)
return false;
if (other.getStepTimeoutInMinutes() != null && other.getStepTimeoutInMinutes().equals(this.getStepTimeoutInMinutes()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getThingName() == null) ? 0 : getThingName().hashCode());
hashCode = prime * hashCode + ((getStatusDetails() == null) ? 0 : getStatusDetails().hashCode());
hashCode = prime * hashCode + ((getStepTimeoutInMinutes() == null) ? 0 : getStepTimeoutInMinutes().hashCode());
return hashCode;
}
@Override
public StartNextPendingJobExecutionRequest clone() {
return (StartNextPendingJobExecutionRequest) super.clone();
}
}