@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getOperationId() == null) ? 0 : getOperationId().hashCode()); hashCode = prime * hashCode + ((getStatus() == null) ? 0 : getStatus().hashCode()); hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getSubmittedDate() == null) ? 0 : getSubmittedDate().hashCode()); return hashCode; }
/** * 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 (getOperationId() != null) sb.append("OperationId: ").append(getOperationId()).append(","); if (getStatus() != null) sb.append("Status: ").append(getStatus()).append(","); if (getType() != null) sb.append("Type: ").append(getType()).append(","); if (getSubmittedDate() != null) sb.append("SubmittedDate: ").append(getSubmittedDate()); sb.append("}"); return sb.toString(); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof OperationSummary == false) return false; OperationSummary other = (OperationSummary) obj; if (other.getOperationId() == null ^ this.getOperationId() == null) return false; if (other.getOperationId() != null && other.getOperationId().equals(this.getOperationId()) == 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.getType() == null ^ this.getType() == null) return false; if (other.getType() != null && other.getType().equals(this.getType()) == false) return false; if (other.getSubmittedDate() == null ^ this.getSubmittedDate() == null) return false; if (other.getSubmittedDate() != null && other.getSubmittedDate().equals(this.getSubmittedDate()) == false) return false; return true; }
/** * Marshall the given parameter object. */ public void marshall(OperationSummary operationSummary, ProtocolMarshaller protocolMarshaller) { if (operationSummary == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(operationSummary.getOperationId(), OPERATIONID_BINDING); protocolMarshaller.marshall(operationSummary.getStatus(), STATUS_BINDING); protocolMarshaller.marshall(operationSummary.getType(), TYPE_BINDING); protocolMarshaller.marshall(operationSummary.getSubmittedDate(), SUBMITTEDDATE_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }