com.amazonaws.services.devicefarm.model.ExecutionConfiguration Maven / Gradle / Ivy
Show all versions of aws-java-sdk-devicefarm Show documentation
/*
* Copyright 2019-2024 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.devicefarm.model;
import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;
/**
*
* Represents configuration information about a test run, such as the execution timeout (in minutes).
*
*
* @see AWS
* API Documentation
*/
@Generated("com.amazonaws:aws-java-sdk-code-generator")
public class ExecutionConfiguration implements Serializable, Cloneable, StructuredPojo {
/**
*
* The number of minutes a test run executes before it times out.
*
*/
private Integer jobTimeoutMinutes;
/**
*
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*
*/
private Boolean accountsCleanup;
/**
*
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*
*/
private Boolean appPackagesCleanup;
/**
*
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*
*/
private Boolean videoCapture;
/**
*
* When set to true
, for private devices, Device Farm does not sign your app again. For public devices,
* Device Farm always signs your apps again.
*
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm FAQs.
*
*/
private Boolean skipAppResign;
/**
*
* The number of minutes a test run executes before it times out.
*
*
* @param jobTimeoutMinutes
* The number of minutes a test run executes before it times out.
*/
public void setJobTimeoutMinutes(Integer jobTimeoutMinutes) {
this.jobTimeoutMinutes = jobTimeoutMinutes;
}
/**
*
* The number of minutes a test run executes before it times out.
*
*
* @return The number of minutes a test run executes before it times out.
*/
public Integer getJobTimeoutMinutes() {
return this.jobTimeoutMinutes;
}
/**
*
* The number of minutes a test run executes before it times out.
*
*
* @param jobTimeoutMinutes
* The number of minutes a test run executes before it times out.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ExecutionConfiguration withJobTimeoutMinutes(Integer jobTimeoutMinutes) {
setJobTimeoutMinutes(jobTimeoutMinutes);
return this;
}
/**
*
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @param accountsCleanup
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public void setAccountsCleanup(Boolean accountsCleanup) {
this.accountsCleanup = accountsCleanup;
}
/**
*
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @return True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public Boolean getAccountsCleanup() {
return this.accountsCleanup;
}
/**
*
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @param accountsCleanup
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ExecutionConfiguration withAccountsCleanup(Boolean accountsCleanup) {
setAccountsCleanup(accountsCleanup);
return this;
}
/**
*
* True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @return True if account cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public Boolean isAccountsCleanup() {
return this.accountsCleanup;
}
/**
*
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @param appPackagesCleanup
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public void setAppPackagesCleanup(Boolean appPackagesCleanup) {
this.appPackagesCleanup = appPackagesCleanup;
}
/**
*
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @return True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public Boolean getAppPackagesCleanup() {
return this.appPackagesCleanup;
}
/**
*
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @param appPackagesCleanup
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ExecutionConfiguration withAppPackagesCleanup(Boolean appPackagesCleanup) {
setAppPackagesCleanup(appPackagesCleanup);
return this;
}
/**
*
* True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*
*
* @return True if app package cleanup is enabled at the beginning of the test. Otherwise, false.
*/
public Boolean isAppPackagesCleanup() {
return this.appPackagesCleanup;
}
/**
*
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*
*
* @param videoCapture
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*/
public void setVideoCapture(Boolean videoCapture) {
this.videoCapture = videoCapture;
}
/**
*
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*
*
* @return Set to true to enable video capture. Otherwise, set to false. The default is true.
*/
public Boolean getVideoCapture() {
return this.videoCapture;
}
/**
*
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*
*
* @param videoCapture
* Set to true to enable video capture. Otherwise, set to false. The default is true.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ExecutionConfiguration withVideoCapture(Boolean videoCapture) {
setVideoCapture(videoCapture);
return this;
}
/**
*
* Set to true to enable video capture. Otherwise, set to false. The default is true.
*
*
* @return Set to true to enable video capture. Otherwise, set to false. The default is true.
*/
public Boolean isVideoCapture() {
return this.videoCapture;
}
/**
*
* When set to true
, for private devices, Device Farm does not sign your app again. For public devices,
* Device Farm always signs your apps again.
*
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm FAQs.
*
*
* @param skipAppResign
* When set to true
, for private devices, Device Farm does not sign your app again. For public
* devices, Device Farm always signs your apps again.
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm
* FAQs.
*/
public void setSkipAppResign(Boolean skipAppResign) {
this.skipAppResign = skipAppResign;
}
/**
*
* When set to true
, for private devices, Device Farm does not sign your app again. For public devices,
* Device Farm always signs your apps again.
*
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm FAQs.
*
*
* @return When set to true
, for private devices, Device Farm does not sign your app again. For public
* devices, Device Farm always signs your apps again.
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm
* FAQs.
*/
public Boolean getSkipAppResign() {
return this.skipAppResign;
}
/**
*
* When set to true
, for private devices, Device Farm does not sign your app again. For public devices,
* Device Farm always signs your apps again.
*
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm FAQs.
*
*
* @param skipAppResign
* When set to true
, for private devices, Device Farm does not sign your app again. For public
* devices, Device Farm always signs your apps again.
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm
* FAQs.
* @return Returns a reference to this object so that method calls can be chained together.
*/
public ExecutionConfiguration withSkipAppResign(Boolean skipAppResign) {
setSkipAppResign(skipAppResign);
return this;
}
/**
*
* When set to true
, for private devices, Device Farm does not sign your app again. For public devices,
* Device Farm always signs your apps again.
*
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm FAQs.
*
*
* @return When set to true
, for private devices, Device Farm does not sign your app again. For public
* devices, Device Farm always signs your apps again.
*
* For more information about how Device Farm re-signs your apps, see Do you modify my app? in the AWS Device Farm
* FAQs.
*/
public Boolean isSkipAppResign() {
return this.skipAppResign;
}
/**
* 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 (getJobTimeoutMinutes() != null)
sb.append("JobTimeoutMinutes: ").append(getJobTimeoutMinutes()).append(",");
if (getAccountsCleanup() != null)
sb.append("AccountsCleanup: ").append(getAccountsCleanup()).append(",");
if (getAppPackagesCleanup() != null)
sb.append("AppPackagesCleanup: ").append(getAppPackagesCleanup()).append(",");
if (getVideoCapture() != null)
sb.append("VideoCapture: ").append(getVideoCapture()).append(",");
if (getSkipAppResign() != null)
sb.append("SkipAppResign: ").append(getSkipAppResign());
sb.append("}");
return sb.toString();
}
@Override
public boolean equals(Object obj) {
if (this == obj)
return true;
if (obj == null)
return false;
if (obj instanceof ExecutionConfiguration == false)
return false;
ExecutionConfiguration other = (ExecutionConfiguration) obj;
if (other.getJobTimeoutMinutes() == null ^ this.getJobTimeoutMinutes() == null)
return false;
if (other.getJobTimeoutMinutes() != null && other.getJobTimeoutMinutes().equals(this.getJobTimeoutMinutes()) == false)
return false;
if (other.getAccountsCleanup() == null ^ this.getAccountsCleanup() == null)
return false;
if (other.getAccountsCleanup() != null && other.getAccountsCleanup().equals(this.getAccountsCleanup()) == false)
return false;
if (other.getAppPackagesCleanup() == null ^ this.getAppPackagesCleanup() == null)
return false;
if (other.getAppPackagesCleanup() != null && other.getAppPackagesCleanup().equals(this.getAppPackagesCleanup()) == false)
return false;
if (other.getVideoCapture() == null ^ this.getVideoCapture() == null)
return false;
if (other.getVideoCapture() != null && other.getVideoCapture().equals(this.getVideoCapture()) == false)
return false;
if (other.getSkipAppResign() == null ^ this.getSkipAppResign() == null)
return false;
if (other.getSkipAppResign() != null && other.getSkipAppResign().equals(this.getSkipAppResign()) == false)
return false;
return true;
}
@Override
public int hashCode() {
final int prime = 31;
int hashCode = 1;
hashCode = prime * hashCode + ((getJobTimeoutMinutes() == null) ? 0 : getJobTimeoutMinutes().hashCode());
hashCode = prime * hashCode + ((getAccountsCleanup() == null) ? 0 : getAccountsCleanup().hashCode());
hashCode = prime * hashCode + ((getAppPackagesCleanup() == null) ? 0 : getAppPackagesCleanup().hashCode());
hashCode = prime * hashCode + ((getVideoCapture() == null) ? 0 : getVideoCapture().hashCode());
hashCode = prime * hashCode + ((getSkipAppResign() == null) ? 0 : getSkipAppResign().hashCode());
return hashCode;
}
@Override
public ExecutionConfiguration clone() {
try {
return (ExecutionConfiguration) super.clone();
} catch (CloneNotSupportedException e) {
throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e);
}
}
@com.amazonaws.annotation.SdkInternalApi
@Override
public void marshall(ProtocolMarshaller protocolMarshaller) {
com.amazonaws.services.devicefarm.model.transform.ExecutionConfigurationMarshaller.getInstance().marshall(this, protocolMarshaller);
}
}