@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getHITId() == null) ? 0 : getHITId().hashCode()); hashCode = prime * hashCode + ((getExpireAt() == null) ? 0 : getExpireAt().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 (getHITId() != null) sb.append("HITId: ").append(getHITId()).append(","); if (getExpireAt() != null) sb.append("ExpireAt: ").append(getExpireAt()); sb.append("}"); return sb.toString(); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof UpdateExpirationForHITRequest == false) return false; UpdateExpirationForHITRequest other = (UpdateExpirationForHITRequest) obj; if (other.getHITId() == null ^ this.getHITId() == null) return false; if (other.getHITId() != null && other.getHITId().equals(this.getHITId()) == false) return false; if (other.getExpireAt() == null ^ this.getExpireAt() == null) return false; if (other.getExpireAt() != null && other.getExpireAt().equals(this.getExpireAt()) == false) return false; return true; }
/** * Marshall the given parameter object. */ public void marshall(UpdateExpirationForHITRequest updateExpirationForHITRequest, ProtocolMarshaller protocolMarshaller) { if (updateExpirationForHITRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(updateExpirationForHITRequest.getHITId(), HITID_BINDING); protocolMarshaller.marshall(updateExpirationForHITRequest.getExpireAt(), EXPIREAT_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }