@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSnapshotId() == null) ? 0 : getSnapshotId().hashCode()); hashCode = prime * hashCode + ((getIops() == null) ? 0 : getIops().hashCode()); hashCode = prime * hashCode + ((getVolumeSize() == null) ? 0 : getVolumeSize().hashCode()); hashCode = prime * hashCode + ((getVolumeType() == null) ? 0 : getVolumeType().hashCode()); hashCode = prime * hashCode + ((getDeleteOnTermination() == null) ? 0 : getDeleteOnTermination().hashCode()); return hashCode; }
/** * <p> * Whether the volume is deleted on instance termination. * </p> * * @param deleteOnTermination * Whether the volume is deleted on instance termination. * @return Returns a reference to this object so that method calls can be chained together. */ public EbsBlockDevice withDeleteOnTermination(Boolean deleteOnTermination) { setDeleteOnTermination(deleteOnTermination); return this; }
/** * <p> * The number of I/O operations per second (IOPS) that the volume supports. For more information, see <a * href="http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_EbsBlockDevice.html">EbsBlockDevice</a>. * </p> * * @param iops * The number of I/O operations per second (IOPS) that the volume supports. For more information, see <a * href="http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_EbsBlockDevice.html">EbsBlockDevice</a>. * @return Returns a reference to this object so that method calls can be chained together. */ public EbsBlockDevice withIops(Integer iops) { setIops(iops); return this; }
public EbsBlockDevice unmarshall(JsonUnmarshallerContext context) throws Exception { EbsBlockDevice ebsBlockDevice = new EbsBlockDevice(); if (context.testExpression("SnapshotId", targetDepth)) { context.nextToken(); ebsBlockDevice.setSnapshotId(context.getUnmarshaller(String.class).unmarshall(context)); ebsBlockDevice.setIops(context.getUnmarshaller(Integer.class).unmarshall(context)); ebsBlockDevice.setVolumeSize(context.getUnmarshaller(Integer.class).unmarshall(context)); ebsBlockDevice.setVolumeType(context.getUnmarshaller(String.class).unmarshall(context)); ebsBlockDevice.setDeleteOnTermination(context.getUnmarshaller(Boolean.class).unmarshall(context));
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getDeviceName() == null) ? 0 : getDeviceName().hashCode()); hashCode = prime * hashCode + ((getNoDevice() == null) ? 0 : getNoDevice().hashCode()); hashCode = prime * hashCode + ((getVirtualName() == null) ? 0 : getVirtualName().hashCode()); hashCode = prime * hashCode + ((getEbs() == null) ? 0 : getEbs().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof BlockDeviceMapping == false) return false; BlockDeviceMapping other = (BlockDeviceMapping) obj; if (other.getDeviceName() == null ^ this.getDeviceName() == null) return false; if (other.getDeviceName() != null && other.getDeviceName().equals(this.getDeviceName()) == false) return false; if (other.getNoDevice() == null ^ this.getNoDevice() == null) return false; if (other.getNoDevice() != null && other.getNoDevice().equals(this.getNoDevice()) == false) return false; if (other.getVirtualName() == null ^ this.getVirtualName() == null) return false; if (other.getVirtualName() != null && other.getVirtualName().equals(this.getVirtualName()) == false) return false; if (other.getEbs() == null ^ this.getEbs() == null) return false; if (other.getEbs() != null && other.getEbs().equals(this.getEbs()) == false) return false; return true; }
public EbsBlockDevice unmarshall(JsonUnmarshallerContext context) throws Exception { EbsBlockDevice ebsBlockDevice = new EbsBlockDevice(); if (context.testExpression("SnapshotId", targetDepth)) { context.nextToken(); ebsBlockDevice.setSnapshotId(context.getUnmarshaller(String.class).unmarshall(context)); ebsBlockDevice.setIops(context.getUnmarshaller(Integer.class).unmarshall(context)); ebsBlockDevice.setVolumeSize(context.getUnmarshaller(Integer.class).unmarshall(context)); ebsBlockDevice.setVolumeType(context.getUnmarshaller(String.class).unmarshall(context)); ebsBlockDevice.setDeleteOnTermination(context.getUnmarshaller(Boolean.class).unmarshall(context));
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getDeviceName() == null) ? 0 : getDeviceName().hashCode()); hashCode = prime * hashCode + ((getNoDevice() == null) ? 0 : getNoDevice().hashCode()); hashCode = prime * hashCode + ((getVirtualName() == null) ? 0 : getVirtualName().hashCode()); hashCode = prime * hashCode + ((getEbs() == null) ? 0 : getEbs().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof BlockDeviceMapping == false) return false; BlockDeviceMapping other = (BlockDeviceMapping) obj; if (other.getDeviceName() == null ^ this.getDeviceName() == null) return false; if (other.getDeviceName() != null && other.getDeviceName().equals(this.getDeviceName()) == false) return false; if (other.getNoDevice() == null ^ this.getNoDevice() == null) return false; if (other.getNoDevice() != null && other.getNoDevice().equals(this.getNoDevice()) == false) return false; if (other.getVirtualName() == null ^ this.getVirtualName() == null) return false; if (other.getVirtualName() != null && other.getVirtualName().equals(this.getVirtualName()) == false) return false; if (other.getEbs() == null ^ this.getEbs() == null) return false; if (other.getEbs() != null && other.getEbs().equals(this.getEbs()) == false) return false; return true; }
return false; EbsBlockDevice other = (EbsBlockDevice) obj; if (other.getSnapshotId() == null ^ this.getSnapshotId() == null) return false; if (other.getSnapshotId() != null && other.getSnapshotId().equals(this.getSnapshotId()) == false) return false; if (other.getIops() == null ^ this.getIops() == null) return false; if (other.getIops() != null && other.getIops().equals(this.getIops()) == false) return false; if (other.getVolumeSize() == null ^ this.getVolumeSize() == null) return false; if (other.getVolumeSize() != null && other.getVolumeSize().equals(this.getVolumeSize()) == false) return false; if (other.getVolumeType() == null ^ this.getVolumeType() == null) return false; if (other.getVolumeType() != null && other.getVolumeType().equals(this.getVolumeType()) == false) return false; if (other.getDeleteOnTermination() == null ^ this.getDeleteOnTermination() == null) return false; if (other.getDeleteOnTermination() != null && other.getDeleteOnTermination().equals(this.getDeleteOnTermination()) == false) return false; return true;
/** * <p> * Whether the volume is deleted on instance termination. * </p> * * @param deleteOnTermination * Whether the volume is deleted on instance termination. * @return Returns a reference to this object so that method calls can be chained together. */ public EbsBlockDevice withDeleteOnTermination(Boolean deleteOnTermination) { setDeleteOnTermination(deleteOnTermination); return this; }
/** * <p> * The number of I/O operations per second (IOPS) that the volume supports. For more information, see <a * href="http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_EbsBlockDevice.html">EbsBlockDevice</a>. * </p> * * @param iops * The number of I/O operations per second (IOPS) that the volume supports. For more information, see <a * href="http://docs.aws.amazon.com/AWSEC2/latest/APIReference/API_EbsBlockDevice.html">EbsBlockDevice</a>. * @return Returns a reference to this object so that method calls can be chained together. */ public EbsBlockDevice withIops(Integer iops) { setIops(iops); 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 (getSnapshotId() != null) sb.append("SnapshotId: ").append(getSnapshotId()).append(","); if (getIops() != null) sb.append("Iops: ").append(getIops()).append(","); if (getVolumeSize() != null) sb.append("VolumeSize: ").append(getVolumeSize()).append(","); if (getVolumeType() != null) sb.append("VolumeType: ").append(getVolumeType()).append(","); if (getDeleteOnTermination() != null) sb.append("DeleteOnTermination: ").append(getDeleteOnTermination()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(EbsBlockDevice ebsBlockDevice, ProtocolMarshaller protocolMarshaller) { if (ebsBlockDevice == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(ebsBlockDevice.getSnapshotId(), SNAPSHOTID_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getIops(), IOPS_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getVolumeSize(), VOLUMESIZE_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getVolumeType(), VOLUMETYPE_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getDeleteOnTermination(), DELETEONTERMINATION_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSnapshotId() == null) ? 0 : getSnapshotId().hashCode()); hashCode = prime * hashCode + ((getIops() == null) ? 0 : getIops().hashCode()); hashCode = prime * hashCode + ((getVolumeSize() == null) ? 0 : getVolumeSize().hashCode()); hashCode = prime * hashCode + ((getVolumeType() == null) ? 0 : getVolumeType().hashCode()); hashCode = prime * hashCode + ((getDeleteOnTermination() == null) ? 0 : getDeleteOnTermination().hashCode()); return hashCode; }
return false; EbsBlockDevice other = (EbsBlockDevice) obj; if (other.getSnapshotId() == null ^ this.getSnapshotId() == null) return false; if (other.getSnapshotId() != null && other.getSnapshotId().equals(this.getSnapshotId()) == false) return false; if (other.getIops() == null ^ this.getIops() == null) return false; if (other.getIops() != null && other.getIops().equals(this.getIops()) == false) return false; if (other.getVolumeSize() == null ^ this.getVolumeSize() == null) return false; if (other.getVolumeSize() != null && other.getVolumeSize().equals(this.getVolumeSize()) == false) return false; if (other.getVolumeType() == null ^ this.getVolumeType() == null) return false; if (other.getVolumeType() != null && other.getVolumeType().equals(this.getVolumeType()) == false) return false; if (other.getDeleteOnTermination() == null ^ this.getDeleteOnTermination() == null) return false; if (other.getDeleteOnTermination() != null && other.getDeleteOnTermination().equals(this.getDeleteOnTermination()) == false) return false; return true;
/** * 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 (getSnapshotId() != null) sb.append("SnapshotId: ").append(getSnapshotId()).append(","); if (getIops() != null) sb.append("Iops: ").append(getIops()).append(","); if (getVolumeSize() != null) sb.append("VolumeSize: ").append(getVolumeSize()).append(","); if (getVolumeType() != null) sb.append("VolumeType: ").append(getVolumeType()).append(","); if (getDeleteOnTermination() != null) sb.append("DeleteOnTermination: ").append(getDeleteOnTermination()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(EbsBlockDevice ebsBlockDevice, ProtocolMarshaller protocolMarshaller) { if (ebsBlockDevice == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(ebsBlockDevice.getSnapshotId(), SNAPSHOTID_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getIops(), IOPS_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getVolumeSize(), VOLUMESIZE_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getVolumeType(), VOLUMETYPE_BINDING); protocolMarshaller.marshall(ebsBlockDevice.getDeleteOnTermination(), DELETEONTERMINATION_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }