public VolumeRecoveryPointInfo unmarshall(JsonUnmarshallerContext context) throws Exception { VolumeRecoveryPointInfo volumeRecoveryPointInfo = new VolumeRecoveryPointInfo(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.currentToken; if (token == null) token = context.nextToken(); while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("VolumeARN", targetDepth)) { context.nextToken(); volumeRecoveryPointInfo.setVolumeARN( StringJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("VolumeSizeInBytes", targetDepth)) { context.nextToken(); volumeRecoveryPointInfo.setVolumeSizeInBytes( LongJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("VolumeUsageInBytes", targetDepth)) { context.nextToken(); volumeRecoveryPointInfo.setVolumeUsageInBytes( LongJsonUnmarshaller.getInstance().unmarshall(context)); } if (context.testExpression("VolumeRecoveryPointTime", targetDepth)) { context.nextToken(); volumeRecoveryPointInfo.setVolumeRecoveryPointTime( StringJsonUnmarshaller.getInstance().unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return volumeRecoveryPointInfo; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof VolumeRecoveryPointInfo == false) return false; VolumeRecoveryPointInfo other = (VolumeRecoveryPointInfo) obj; if (other.getVolumeARN() == null ^ this.getVolumeARN() == null) return false; if (other.getVolumeARN() != null && other.getVolumeARN().equals(this.getVolumeARN()) == false) return false; if (other.getVolumeSizeInBytes() == null ^ this.getVolumeSizeInBytes() == null) return false; if (other.getVolumeSizeInBytes() != null && other.getVolumeSizeInBytes().equals(this.getVolumeSizeInBytes()) == false) return false; if (other.getVolumeUsageInBytes() == null ^ this.getVolumeUsageInBytes() == null) return false; if (other.getVolumeUsageInBytes() != null && other.getVolumeUsageInBytes().equals(this.getVolumeUsageInBytes()) == false) return false; if (other.getVolumeRecoveryPointTime() == null ^ this.getVolumeRecoveryPointTime() == null) return false; if (other.getVolumeRecoveryPointTime() != null && other.getVolumeRecoveryPointTime().equals(this.getVolumeRecoveryPointTime()) == false) return false; return true; }