/* * 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.ec2.model; import java.io.Serializable; import javax.annotation.Generated; /** *
* Describes an export instance task. *
* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ExportTask implements Serializable, Cloneable { /** ** A description of the resource being exported. *
*/ private String description; /** ** The ID of the export task. *
*/ private String exportTaskId; /** ** Information about the export task. *
*/ private ExportToS3Task exportToS3Task; /** ** Information about the instance to export. *
*/ private InstanceExportDetails instanceExportDetails; /** ** The state of the export task. *
*/ private String state; /** ** The status message related to the export task. *
*/ private String statusMessage; /** ** The tags for the export task. *
*/ private com.amazonaws.internal.SdkInternalList* A description of the resource being exported. *
* * @param description * A description of the resource being exported. */ public void setDescription(String description) { this.description = description; } /** ** A description of the resource being exported. *
* * @return A description of the resource being exported. */ public String getDescription() { return this.description; } /** ** A description of the resource being exported. *
* * @param description * A description of the resource being exported. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withDescription(String description) { setDescription(description); return this; } /** ** The ID of the export task. *
* * @param exportTaskId * The ID of the export task. */ public void setExportTaskId(String exportTaskId) { this.exportTaskId = exportTaskId; } /** ** The ID of the export task. *
* * @return The ID of the export task. */ public String getExportTaskId() { return this.exportTaskId; } /** ** The ID of the export task. *
* * @param exportTaskId * The ID of the export task. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withExportTaskId(String exportTaskId) { setExportTaskId(exportTaskId); return this; } /** ** Information about the export task. *
* * @param exportToS3Task * Information about the export task. */ public void setExportToS3Task(ExportToS3Task exportToS3Task) { this.exportToS3Task = exportToS3Task; } /** ** Information about the export task. *
* * @return Information about the export task. */ public ExportToS3Task getExportToS3Task() { return this.exportToS3Task; } /** ** Information about the export task. *
* * @param exportToS3Task * Information about the export task. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withExportToS3Task(ExportToS3Task exportToS3Task) { setExportToS3Task(exportToS3Task); return this; } /** ** Information about the instance to export. *
* * @param instanceExportDetails * Information about the instance to export. */ public void setInstanceExportDetails(InstanceExportDetails instanceExportDetails) { this.instanceExportDetails = instanceExportDetails; } /** ** Information about the instance to export. *
* * @return Information about the instance to export. */ public InstanceExportDetails getInstanceExportDetails() { return this.instanceExportDetails; } /** ** Information about the instance to export. *
* * @param instanceExportDetails * Information about the instance to export. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withInstanceExportDetails(InstanceExportDetails instanceExportDetails) { setInstanceExportDetails(instanceExportDetails); return this; } /** ** The state of the export task. *
* * @param state * The state of the export task. * @see ExportTaskState */ public void setState(String state) { this.state = state; } /** ** The state of the export task. *
* * @return The state of the export task. * @see ExportTaskState */ public String getState() { return this.state; } /** ** The state of the export task. *
* * @param state * The state of the export task. * @return Returns a reference to this object so that method calls can be chained together. * @see ExportTaskState */ public ExportTask withState(String state) { setState(state); return this; } /** ** The state of the export task. *
* * @param state * The state of the export task. * @see ExportTaskState */ public void setState(ExportTaskState state) { withState(state); } /** ** The state of the export task. *
* * @param state * The state of the export task. * @return Returns a reference to this object so that method calls can be chained together. * @see ExportTaskState */ public ExportTask withState(ExportTaskState state) { this.state = state.toString(); return this; } /** ** The status message related to the export task. *
* * @param statusMessage * The status message related to the export task. */ public void setStatusMessage(String statusMessage) { this.statusMessage = statusMessage; } /** ** The status message related to the export task. *
* * @return The status message related to the export task. */ public String getStatusMessage() { return this.statusMessage; } /** ** The status message related to the export task. *
* * @param statusMessage * The status message related to the export task. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withStatusMessage(String statusMessage) { setStatusMessage(statusMessage); return this; } /** ** The tags for the export task. *
* * @return The tags for the export task. */ public java.util.List* The tags for the export task. *
* * @param tags * The tags for the export task. */ public void setTags(java.util.Collection* The tags for the export task. *
** 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 * The tags for the export task. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withTags(Tag... tags) { if (this.tags == null) { setTags(new com.amazonaws.internal.SdkInternalList* The tags for the export task. *
* * @param tags * The tags for the export task. * @return Returns a reference to this object so that method calls can be chained together. */ public ExportTask withTags(java.util.Collection