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

com.amazonaws.services.drs.model.DataReplicationInfo Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Elastic Disaster Recovery module holds the client classes that are used for communicating with Elastic Disaster Recovery Service

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

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

/**
 * 

* Information about Data Replication *

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

* Error in data replication. *

*/ private DataReplicationError dataReplicationError; /** *

* Information about whether the data replication has been initiated. *

*/ private DataReplicationInitiation dataReplicationInitiation; /** *

* The state of the data replication. *

*/ private String dataReplicationState; /** *

* An estimate of when the data replication will be completed. *

*/ private String etaDateTime; /** *

* Data replication lag duration. *

*/ private String lagDuration; /** *

* The disks that should be replicated. *

*/ private java.util.List replicatedDisks; /** *

* AWS Availability zone into which data is being replicated. *

*/ private String stagingAvailabilityZone; /** *

* Error in data replication. *

* * @param dataReplicationError * Error in data replication. */ public void setDataReplicationError(DataReplicationError dataReplicationError) { this.dataReplicationError = dataReplicationError; } /** *

* Error in data replication. *

* * @return Error in data replication. */ public DataReplicationError getDataReplicationError() { return this.dataReplicationError; } /** *

* Error in data replication. *

* * @param dataReplicationError * Error in data replication. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withDataReplicationError(DataReplicationError dataReplicationError) { setDataReplicationError(dataReplicationError); return this; } /** *

* Information about whether the data replication has been initiated. *

* * @param dataReplicationInitiation * Information about whether the data replication has been initiated. */ public void setDataReplicationInitiation(DataReplicationInitiation dataReplicationInitiation) { this.dataReplicationInitiation = dataReplicationInitiation; } /** *

* Information about whether the data replication has been initiated. *

* * @return Information about whether the data replication has been initiated. */ public DataReplicationInitiation getDataReplicationInitiation() { return this.dataReplicationInitiation; } /** *

* Information about whether the data replication has been initiated. *

* * @param dataReplicationInitiation * Information about whether the data replication has been initiated. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withDataReplicationInitiation(DataReplicationInitiation dataReplicationInitiation) { setDataReplicationInitiation(dataReplicationInitiation); return this; } /** *

* The state of the data replication. *

* * @param dataReplicationState * The state of the data replication. * @see DataReplicationState */ public void setDataReplicationState(String dataReplicationState) { this.dataReplicationState = dataReplicationState; } /** *

* The state of the data replication. *

* * @return The state of the data replication. * @see DataReplicationState */ public String getDataReplicationState() { return this.dataReplicationState; } /** *

* The state of the data replication. *

* * @param dataReplicationState * The state of the data replication. * @return Returns a reference to this object so that method calls can be chained together. * @see DataReplicationState */ public DataReplicationInfo withDataReplicationState(String dataReplicationState) { setDataReplicationState(dataReplicationState); return this; } /** *

* The state of the data replication. *

* * @param dataReplicationState * The state of the data replication. * @return Returns a reference to this object so that method calls can be chained together. * @see DataReplicationState */ public DataReplicationInfo withDataReplicationState(DataReplicationState dataReplicationState) { this.dataReplicationState = dataReplicationState.toString(); return this; } /** *

* An estimate of when the data replication will be completed. *

* * @param etaDateTime * An estimate of when the data replication will be completed. */ public void setEtaDateTime(String etaDateTime) { this.etaDateTime = etaDateTime; } /** *

* An estimate of when the data replication will be completed. *

* * @return An estimate of when the data replication will be completed. */ public String getEtaDateTime() { return this.etaDateTime; } /** *

* An estimate of when the data replication will be completed. *

* * @param etaDateTime * An estimate of when the data replication will be completed. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withEtaDateTime(String etaDateTime) { setEtaDateTime(etaDateTime); return this; } /** *

* Data replication lag duration. *

* * @param lagDuration * Data replication lag duration. */ public void setLagDuration(String lagDuration) { this.lagDuration = lagDuration; } /** *

* Data replication lag duration. *

* * @return Data replication lag duration. */ public String getLagDuration() { return this.lagDuration; } /** *

* Data replication lag duration. *

* * @param lagDuration * Data replication lag duration. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withLagDuration(String lagDuration) { setLagDuration(lagDuration); return this; } /** *

* The disks that should be replicated. *

* * @return The disks that should be replicated. */ public java.util.List getReplicatedDisks() { return replicatedDisks; } /** *

* The disks that should be replicated. *

* * @param replicatedDisks * The disks that should be replicated. */ public void setReplicatedDisks(java.util.Collection replicatedDisks) { if (replicatedDisks == null) { this.replicatedDisks = null; return; } this.replicatedDisks = new java.util.ArrayList(replicatedDisks); } /** *

* The disks that should be replicated. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setReplicatedDisks(java.util.Collection)} or {@link #withReplicatedDisks(java.util.Collection)} if you * want to override the existing values. *

* * @param replicatedDisks * The disks that should be replicated. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withReplicatedDisks(DataReplicationInfoReplicatedDisk... replicatedDisks) { if (this.replicatedDisks == null) { setReplicatedDisks(new java.util.ArrayList(replicatedDisks.length)); } for (DataReplicationInfoReplicatedDisk ele : replicatedDisks) { this.replicatedDisks.add(ele); } return this; } /** *

* The disks that should be replicated. *

* * @param replicatedDisks * The disks that should be replicated. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withReplicatedDisks(java.util.Collection replicatedDisks) { setReplicatedDisks(replicatedDisks); return this; } /** *

* AWS Availability zone into which data is being replicated. *

* * @param stagingAvailabilityZone * AWS Availability zone into which data is being replicated. */ public void setStagingAvailabilityZone(String stagingAvailabilityZone) { this.stagingAvailabilityZone = stagingAvailabilityZone; } /** *

* AWS Availability zone into which data is being replicated. *

* * @return AWS Availability zone into which data is being replicated. */ public String getStagingAvailabilityZone() { return this.stagingAvailabilityZone; } /** *

* AWS Availability zone into which data is being replicated. *

* * @param stagingAvailabilityZone * AWS Availability zone into which data is being replicated. * @return Returns a reference to this object so that method calls can be chained together. */ public DataReplicationInfo withStagingAvailabilityZone(String stagingAvailabilityZone) { setStagingAvailabilityZone(stagingAvailabilityZone); 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 (getDataReplicationError() != null) sb.append("DataReplicationError: ").append(getDataReplicationError()).append(","); if (getDataReplicationInitiation() != null) sb.append("DataReplicationInitiation: ").append(getDataReplicationInitiation()).append(","); if (getDataReplicationState() != null) sb.append("DataReplicationState: ").append(getDataReplicationState()).append(","); if (getEtaDateTime() != null) sb.append("EtaDateTime: ").append(getEtaDateTime()).append(","); if (getLagDuration() != null) sb.append("LagDuration: ").append(getLagDuration()).append(","); if (getReplicatedDisks() != null) sb.append("ReplicatedDisks: ").append(getReplicatedDisks()).append(","); if (getStagingAvailabilityZone() != null) sb.append("StagingAvailabilityZone: ").append(getStagingAvailabilityZone()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DataReplicationInfo == false) return false; DataReplicationInfo other = (DataReplicationInfo) obj; if (other.getDataReplicationError() == null ^ this.getDataReplicationError() == null) return false; if (other.getDataReplicationError() != null && other.getDataReplicationError().equals(this.getDataReplicationError()) == false) return false; if (other.getDataReplicationInitiation() == null ^ this.getDataReplicationInitiation() == null) return false; if (other.getDataReplicationInitiation() != null && other.getDataReplicationInitiation().equals(this.getDataReplicationInitiation()) == false) return false; if (other.getDataReplicationState() == null ^ this.getDataReplicationState() == null) return false; if (other.getDataReplicationState() != null && other.getDataReplicationState().equals(this.getDataReplicationState()) == false) return false; if (other.getEtaDateTime() == null ^ this.getEtaDateTime() == null) return false; if (other.getEtaDateTime() != null && other.getEtaDateTime().equals(this.getEtaDateTime()) == false) return false; if (other.getLagDuration() == null ^ this.getLagDuration() == null) return false; if (other.getLagDuration() != null && other.getLagDuration().equals(this.getLagDuration()) == false) return false; if (other.getReplicatedDisks() == null ^ this.getReplicatedDisks() == null) return false; if (other.getReplicatedDisks() != null && other.getReplicatedDisks().equals(this.getReplicatedDisks()) == false) return false; if (other.getStagingAvailabilityZone() == null ^ this.getStagingAvailabilityZone() == null) return false; if (other.getStagingAvailabilityZone() != null && other.getStagingAvailabilityZone().equals(this.getStagingAvailabilityZone()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getDataReplicationError() == null) ? 0 : getDataReplicationError().hashCode()); hashCode = prime * hashCode + ((getDataReplicationInitiation() == null) ? 0 : getDataReplicationInitiation().hashCode()); hashCode = prime * hashCode + ((getDataReplicationState() == null) ? 0 : getDataReplicationState().hashCode()); hashCode = prime * hashCode + ((getEtaDateTime() == null) ? 0 : getEtaDateTime().hashCode()); hashCode = prime * hashCode + ((getLagDuration() == null) ? 0 : getLagDuration().hashCode()); hashCode = prime * hashCode + ((getReplicatedDisks() == null) ? 0 : getReplicatedDisks().hashCode()); hashCode = prime * hashCode + ((getStagingAvailabilityZone() == null) ? 0 : getStagingAvailabilityZone().hashCode()); return hashCode; } @Override public DataReplicationInfo clone() { try { return (DataReplicationInfo) 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.drs.model.transform.DataReplicationInfoMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy