All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.personalize.model.DataDeletionJob Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Amazon Personalize module holds the client classes that are used for communicating with Amazon Personalize Service

There is a newer version: 1.12.780
Show newest version
/*
 * 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.personalize.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Describes a job that deletes all references to specific users from an Amazon Personalize dataset group in batches. * For information about creating a data deletion job, see Deleting users. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class DataDeletionJob implements Serializable, Cloneable, StructuredPojo { /** *

* The name of the data deletion job. *

*/ private String jobName; /** *

* The Amazon Resource Name (ARN) of the data deletion job. *

*/ private String dataDeletionJobArn; /** *

* The Amazon Resource Name (ARN) of the dataset group the job deletes records from. *

*/ private String datasetGroupArn; private DataSource dataSource; /** *

* The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data source. *

*/ private String roleArn; /** *

* The status of the data deletion job. *

*

* A data deletion job can have one of the following statuses: *

*
    *
  • *

    * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

    *
  • *
*/ private String status; /** *

* The number of records deleted by a COMPLETED job. *

*/ private Integer numDeleted; /** *

* The creation date and time (in Unix time) of the data deletion job. *

*/ private java.util.Date creationDateTime; /** *

* The date and time (in Unix time) the data deletion job was last updated. *

*/ private java.util.Date lastUpdatedDateTime; /** *

* If a data deletion job fails, provides the reason why. *

*/ private String failureReason; /** *

* The name of the data deletion job. *

* * @param jobName * The name of the data deletion job. */ public void setJobName(String jobName) { this.jobName = jobName; } /** *

* The name of the data deletion job. *

* * @return The name of the data deletion job. */ public String getJobName() { return this.jobName; } /** *

* The name of the data deletion job. *

* * @param jobName * The name of the data deletion job. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withJobName(String jobName) { setJobName(jobName); return this; } /** *

* The Amazon Resource Name (ARN) of the data deletion job. *

* * @param dataDeletionJobArn * The Amazon Resource Name (ARN) of the data deletion job. */ public void setDataDeletionJobArn(String dataDeletionJobArn) { this.dataDeletionJobArn = dataDeletionJobArn; } /** *

* The Amazon Resource Name (ARN) of the data deletion job. *

* * @return The Amazon Resource Name (ARN) of the data deletion job. */ public String getDataDeletionJobArn() { return this.dataDeletionJobArn; } /** *

* The Amazon Resource Name (ARN) of the data deletion job. *

* * @param dataDeletionJobArn * The Amazon Resource Name (ARN) of the data deletion job. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withDataDeletionJobArn(String dataDeletionJobArn) { setDataDeletionJobArn(dataDeletionJobArn); return this; } /** *

* The Amazon Resource Name (ARN) of the dataset group the job deletes records from. *

* * @param datasetGroupArn * The Amazon Resource Name (ARN) of the dataset group the job deletes records from. */ public void setDatasetGroupArn(String datasetGroupArn) { this.datasetGroupArn = datasetGroupArn; } /** *

* The Amazon Resource Name (ARN) of the dataset group the job deletes records from. *

* * @return The Amazon Resource Name (ARN) of the dataset group the job deletes records from. */ public String getDatasetGroupArn() { return this.datasetGroupArn; } /** *

* The Amazon Resource Name (ARN) of the dataset group the job deletes records from. *

* * @param datasetGroupArn * The Amazon Resource Name (ARN) of the dataset group the job deletes records from. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withDatasetGroupArn(String datasetGroupArn) { setDatasetGroupArn(datasetGroupArn); return this; } /** * @param dataSource */ public void setDataSource(DataSource dataSource) { this.dataSource = dataSource; } /** * @return */ public DataSource getDataSource() { return this.dataSource; } /** * @param dataSource * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withDataSource(DataSource dataSource) { setDataSource(dataSource); return this; } /** *

* The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data source. *

* * @param roleArn * The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data * source. */ public void setRoleArn(String roleArn) { this.roleArn = roleArn; } /** *

* The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data source. *

* * @return The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data * source. */ public String getRoleArn() { return this.roleArn; } /** *

* The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data source. *

* * @param roleArn * The Amazon Resource Name (ARN) of the IAM role that has permissions to read from the Amazon S3 data * source. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withRoleArn(String roleArn) { setRoleArn(roleArn); return this; } /** *

* The status of the data deletion job. *

*

* A data deletion job can have one of the following statuses: *

*
    *
  • *

    * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

    *
  • *
* * @param status * The status of the data deletion job.

*

* A data deletion job can have one of the following statuses: *

*
    *
  • *

    * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

    *
  • */ public void setStatus(String status) { this.status = status; } /** *

    * The status of the data deletion job. *

    *

    * A data deletion job can have one of the following statuses: *

    *
      *
    • *

      * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

      *
    • *
    * * @return The status of the data deletion job.

    *

    * A data deletion job can have one of the following statuses: *

    *
      *
    • *

      * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

      *
    • */ public String getStatus() { return this.status; } /** *

      * The status of the data deletion job. *

      *

      * A data deletion job can have one of the following statuses: *

      *
        *
      • *

        * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

        *
      • *
      * * @param status * The status of the data deletion job.

      *

      * A data deletion job can have one of the following statuses: *

      *
        *
      • *

        * PENDING > IN_PROGRESS > COMPLETED -or- FAILED *

        *
      • * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withStatus(String status) { setStatus(status); return this; } /** *

        * The number of records deleted by a COMPLETED job. *

        * * @param numDeleted * The number of records deleted by a COMPLETED job. */ public void setNumDeleted(Integer numDeleted) { this.numDeleted = numDeleted; } /** *

        * The number of records deleted by a COMPLETED job. *

        * * @return The number of records deleted by a COMPLETED job. */ public Integer getNumDeleted() { return this.numDeleted; } /** *

        * The number of records deleted by a COMPLETED job. *

        * * @param numDeleted * The number of records deleted by a COMPLETED job. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withNumDeleted(Integer numDeleted) { setNumDeleted(numDeleted); return this; } /** *

        * The creation date and time (in Unix time) of the data deletion job. *

        * * @param creationDateTime * The creation date and time (in Unix time) of the data deletion job. */ public void setCreationDateTime(java.util.Date creationDateTime) { this.creationDateTime = creationDateTime; } /** *

        * The creation date and time (in Unix time) of the data deletion job. *

        * * @return The creation date and time (in Unix time) of the data deletion job. */ public java.util.Date getCreationDateTime() { return this.creationDateTime; } /** *

        * The creation date and time (in Unix time) of the data deletion job. *

        * * @param creationDateTime * The creation date and time (in Unix time) of the data deletion job. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withCreationDateTime(java.util.Date creationDateTime) { setCreationDateTime(creationDateTime); return this; } /** *

        * The date and time (in Unix time) the data deletion job was last updated. *

        * * @param lastUpdatedDateTime * The date and time (in Unix time) the data deletion job was last updated. */ public void setLastUpdatedDateTime(java.util.Date lastUpdatedDateTime) { this.lastUpdatedDateTime = lastUpdatedDateTime; } /** *

        * The date and time (in Unix time) the data deletion job was last updated. *

        * * @return The date and time (in Unix time) the data deletion job was last updated. */ public java.util.Date getLastUpdatedDateTime() { return this.lastUpdatedDateTime; } /** *

        * The date and time (in Unix time) the data deletion job was last updated. *

        * * @param lastUpdatedDateTime * The date and time (in Unix time) the data deletion job was last updated. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withLastUpdatedDateTime(java.util.Date lastUpdatedDateTime) { setLastUpdatedDateTime(lastUpdatedDateTime); return this; } /** *

        * If a data deletion job fails, provides the reason why. *

        * * @param failureReason * If a data deletion job fails, provides the reason why. */ public void setFailureReason(String failureReason) { this.failureReason = failureReason; } /** *

        * If a data deletion job fails, provides the reason why. *

        * * @return If a data deletion job fails, provides the reason why. */ public String getFailureReason() { return this.failureReason; } /** *

        * If a data deletion job fails, provides the reason why. *

        * * @param failureReason * If a data deletion job fails, provides the reason why. * @return Returns a reference to this object so that method calls can be chained together. */ public DataDeletionJob withFailureReason(String failureReason) { setFailureReason(failureReason); 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 (getJobName() != null) sb.append("JobName: ").append(getJobName()).append(","); if (getDataDeletionJobArn() != null) sb.append("DataDeletionJobArn: ").append(getDataDeletionJobArn()).append(","); if (getDatasetGroupArn() != null) sb.append("DatasetGroupArn: ").append(getDatasetGroupArn()).append(","); if (getDataSource() != null) sb.append("DataSource: ").append(getDataSource()).append(","); if (getRoleArn() != null) sb.append("RoleArn: ").append(getRoleArn()).append(","); if (getStatus() != null) sb.append("Status: ").append(getStatus()).append(","); if (getNumDeleted() != null) sb.append("NumDeleted: ").append(getNumDeleted()).append(","); if (getCreationDateTime() != null) sb.append("CreationDateTime: ").append(getCreationDateTime()).append(","); if (getLastUpdatedDateTime() != null) sb.append("LastUpdatedDateTime: ").append(getLastUpdatedDateTime()).append(","); if (getFailureReason() != null) sb.append("FailureReason: ").append(getFailureReason()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DataDeletionJob == false) return false; DataDeletionJob other = (DataDeletionJob) obj; if (other.getJobName() == null ^ this.getJobName() == null) return false; if (other.getJobName() != null && other.getJobName().equals(this.getJobName()) == false) return false; if (other.getDataDeletionJobArn() == null ^ this.getDataDeletionJobArn() == null) return false; if (other.getDataDeletionJobArn() != null && other.getDataDeletionJobArn().equals(this.getDataDeletionJobArn()) == false) return false; if (other.getDatasetGroupArn() == null ^ this.getDatasetGroupArn() == null) return false; if (other.getDatasetGroupArn() != null && other.getDatasetGroupArn().equals(this.getDatasetGroupArn()) == false) return false; if (other.getDataSource() == null ^ this.getDataSource() == null) return false; if (other.getDataSource() != null && other.getDataSource().equals(this.getDataSource()) == false) return false; if (other.getRoleArn() == null ^ this.getRoleArn() == null) return false; if (other.getRoleArn() != null && other.getRoleArn().equals(this.getRoleArn()) == false) return false; if (other.getStatus() == null ^ this.getStatus() == null) return false; if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; if (other.getNumDeleted() == null ^ this.getNumDeleted() == null) return false; if (other.getNumDeleted() != null && other.getNumDeleted().equals(this.getNumDeleted()) == false) return false; if (other.getCreationDateTime() == null ^ this.getCreationDateTime() == null) return false; if (other.getCreationDateTime() != null && other.getCreationDateTime().equals(this.getCreationDateTime()) == false) return false; if (other.getLastUpdatedDateTime() == null ^ this.getLastUpdatedDateTime() == null) return false; if (other.getLastUpdatedDateTime() != null && other.getLastUpdatedDateTime().equals(this.getLastUpdatedDateTime()) == false) return false; if (other.getFailureReason() == null ^ this.getFailureReason() == null) return false; if (other.getFailureReason() != null && other.getFailureReason().equals(this.getFailureReason()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getJobName() == null) ? 0 : getJobName().hashCode()); hashCode = prime * hashCode + ((getDataDeletionJobArn() == null) ? 0 : getDataDeletionJobArn().hashCode()); hashCode = prime * hashCode + ((getDatasetGroupArn() == null) ? 0 : getDatasetGroupArn().hashCode()); hashCode = prime * hashCode + ((getDataSource() == null) ? 0 : getDataSource().hashCode()); hashCode = prime * hashCode + ((getRoleArn() == null) ? 0 : getRoleArn().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getNumDeleted() == null) ? 0 : getNumDeleted().hashCode()); hashCode = prime * hashCode + ((getCreationDateTime() == null) ? 0 : getCreationDateTime().hashCode()); hashCode = prime * hashCode + ((getLastUpdatedDateTime() == null) ? 0 : getLastUpdatedDateTime().hashCode()); hashCode = prime * hashCode + ((getFailureReason() == null) ? 0 : getFailureReason().hashCode()); return hashCode; } @Override public DataDeletionJob clone() { try { return (DataDeletionJob) 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.personalize.model.transform.DataDeletionJobMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy