@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getVolumeId() == null) ? 0 : getVolumeId().hashCode()); hashCode = prime * hashCode + ((getEc2VolumeId() == null) ? 0 : getEc2VolumeId().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getRaidArrayId() == null) ? 0 : getRaidArrayId().hashCode()); hashCode = prime * hashCode + ((getInstanceId() == null) ? 0 : getInstanceId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getSize() == null) ? 0 : getSize().hashCode()); hashCode = prime * hashCode + ((getDevice() == null) ? 0 : getDevice().hashCode()); hashCode = prime * hashCode + ((getMountPoint() == null) ? 0 : getMountPoint().hashCode()); hashCode = prime * hashCode + ((getRegion() == null) ? 0 : getRegion().hashCode()); hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode()); hashCode = prime * hashCode + ((getVolumeType() == null) ? 0 : getVolumeType().hashCode()); hashCode = prime * hashCode + ((getIops() == null) ? 0 : getIops().hashCode()); hashCode = prime * hashCode + ((getEncrypted() == null) ? 0 : getEncrypted().hashCode()); return hashCode; }
if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; if (other.getSize() == null ^ this.getSize() == null) return false; if (other.getSize() != null && other.getSize().equals(this.getSize()) == false) return false; if (other.getDevice() == null ^ this.getDevice() == null)
/** * Marshall the given parameter object. */ public void marshall(Volume volume, ProtocolMarshaller protocolMarshaller) { if (volume == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(volume.getVolumeId(), VOLUMEID_BINDING); protocolMarshaller.marshall(volume.getEc2VolumeId(), EC2VOLUMEID_BINDING); protocolMarshaller.marshall(volume.getName(), NAME_BINDING); protocolMarshaller.marshall(volume.getRaidArrayId(), RAIDARRAYID_BINDING); protocolMarshaller.marshall(volume.getInstanceId(), INSTANCEID_BINDING); protocolMarshaller.marshall(volume.getStatus(), STATUS_BINDING); protocolMarshaller.marshall(volume.getSize(), SIZE_BINDING); protocolMarshaller.marshall(volume.getDevice(), DEVICE_BINDING); protocolMarshaller.marshall(volume.getMountPoint(), MOUNTPOINT_BINDING); protocolMarshaller.marshall(volume.getRegion(), REGION_BINDING); protocolMarshaller.marshall(volume.getAvailabilityZone(), AVAILABILITYZONE_BINDING); protocolMarshaller.marshall(volume.getVolumeType(), VOLUMETYPE_BINDING); protocolMarshaller.marshall(volume.getIops(), IOPS_BINDING); protocolMarshaller.marshall(volume.getEncrypted(), ENCRYPTED_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 + ((getVolumeId() == null) ? 0 : getVolumeId().hashCode()); hashCode = prime * hashCode + ((getEc2VolumeId() == null) ? 0 : getEc2VolumeId().hashCode()); hashCode = prime * hashCode + ((getName() == null) ? 0 : getName().hashCode()); hashCode = prime * hashCode + ((getRaidArrayId() == null) ? 0 : getRaidArrayId().hashCode()); hashCode = prime * hashCode + ((getInstanceId() == null) ? 0 : getInstanceId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getSize() == null) ? 0 : getSize().hashCode()); hashCode = prime * hashCode + ((getDevice() == null) ? 0 : getDevice().hashCode()); hashCode = prime * hashCode + ((getMountPoint() == null) ? 0 : getMountPoint().hashCode()); hashCode = prime * hashCode + ((getRegion() == null) ? 0 : getRegion().hashCode()); hashCode = prime * hashCode + ((getAvailabilityZone() == null) ? 0 : getAvailabilityZone().hashCode()); hashCode = prime * hashCode + ((getVolumeType() == null) ? 0 : getVolumeType().hashCode()); hashCode = prime * hashCode + ((getIops() == null) ? 0 : getIops().hashCode()); hashCode = prime * hashCode + ((getEncrypted() == null) ? 0 : getEncrypted().hashCode()); return hashCode; }
if (other.getStatus() != null && other.getStatus().equals(this.getStatus()) == false) return false; if (other.getSize() == null ^ this.getSize() == null) return false; if (other.getSize() != null && other.getSize().equals(this.getSize()) == false) return false; if (other.getDevice() == null ^ this.getDevice() == null)
/** * Marshall the given parameter object. */ public void marshall(Volume volume, ProtocolMarshaller protocolMarshaller) { if (volume == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(volume.getVolumeId(), VOLUMEID_BINDING); protocolMarshaller.marshall(volume.getEc2VolumeId(), EC2VOLUMEID_BINDING); protocolMarshaller.marshall(volume.getName(), NAME_BINDING); protocolMarshaller.marshall(volume.getRaidArrayId(), RAIDARRAYID_BINDING); protocolMarshaller.marshall(volume.getInstanceId(), INSTANCEID_BINDING); protocolMarshaller.marshall(volume.getStatus(), STATUS_BINDING); protocolMarshaller.marshall(volume.getSize(), SIZE_BINDING); protocolMarshaller.marshall(volume.getDevice(), DEVICE_BINDING); protocolMarshaller.marshall(volume.getMountPoint(), MOUNTPOINT_BINDING); protocolMarshaller.marshall(volume.getRegion(), REGION_BINDING); protocolMarshaller.marshall(volume.getAvailabilityZone(), AVAILABILITYZONE_BINDING); protocolMarshaller.marshall(volume.getVolumeType(), VOLUMETYPE_BINDING); protocolMarshaller.marshall(volume.getIops(), IOPS_BINDING); protocolMarshaller.marshall(volume.getEncrypted(), ENCRYPTED_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }