@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAttributeName() == null) ? 0 : getAttributeName().hashCode()); hashCode = prime * hashCode + ((getElementName() == null) ? 0 : getElementName().hashCode()); hashCode = prime * hashCode + ((getReason() == null) ? 0 : getReason().hashCode()); return hashCode; }
/** * The name of the XML attribute that has been sanitized. * * @param attributeName * The name of the XML attribute that has been sanitized. * @return Returns a reference to this object so that method calls can be chained together. */ public SanitizationWarning withAttributeName(String attributeName) { setAttributeName(attributeName); return this; }
/** * The name of the XML element that has been sanitized. * * @param elementName * The name of the XML element that has been sanitized. * @return Returns a reference to this object so that method calls can be chained together. */ public SanitizationWarning withElementName(String elementName) { setElementName(elementName); return this; }
public SanitizationWarning unmarshall(JsonUnmarshallerContext context) throws Exception { SanitizationWarning sanitizationWarning = new SanitizationWarning(); if (context.testExpression("attributeName", targetDepth)) { context.nextToken(); sanitizationWarning.setAttributeName(context.getUnmarshaller(String.class).unmarshall(context)); sanitizationWarning.setElementName(context.getUnmarshaller(String.class).unmarshall(context)); sanitizationWarning.setReason(context.getUnmarshaller(String.class).unmarshall(context));
/** * Required. The reason for which the XML elements or attributes were sanitized. * * @param reason * Required. The reason for which the XML elements or attributes were sanitized. * @return Returns a reference to this object so that method calls can be chained together. * @see SanitizationWarningReason */ public SanitizationWarning withReason(String reason) { setReason(reason); return this; }
public SanitizationWarning unmarshall(JsonUnmarshallerContext context) throws Exception { SanitizationWarning sanitizationWarning = new SanitizationWarning(); if (context.testExpression("attributeName", targetDepth)) { context.nextToken(); sanitizationWarning.setAttributeName(context.getUnmarshaller(String.class).unmarshall(context)); sanitizationWarning.setElementName(context.getUnmarshaller(String.class).unmarshall(context)); sanitizationWarning.setReason(context.getUnmarshaller(String.class).unmarshall(context));
/** * Required. The reason for which the XML elements or attributes were sanitized. * * @param reason * Required. The reason for which the XML elements or attributes were sanitized. * @return Returns a reference to this object so that method calls can be chained together. * @see SanitizationWarningReason */ public SanitizationWarning withReason(String reason) { setReason(reason); return this; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SanitizationWarning == false) return false; SanitizationWarning other = (SanitizationWarning) obj; if (other.getAttributeName() == null ^ this.getAttributeName() == null) return false; if (other.getAttributeName() != null && other.getAttributeName().equals(this.getAttributeName()) == false) return false; if (other.getElementName() == null ^ this.getElementName() == null) return false; if (other.getElementName() != null && other.getElementName().equals(this.getElementName()) == false) return false; if (other.getReason() == null ^ this.getReason() == null) return false; if (other.getReason() != null && other.getReason().equals(this.getReason()) == false) return false; return true; }
/** * The name of the XML attribute that has been sanitized. * * @param attributeName * The name of the XML attribute that has been sanitized. * @return Returns a reference to this object so that method calls can be chained together. */ public SanitizationWarning withAttributeName(String attributeName) { setAttributeName(attributeName); return this; }
/** * The name of the XML element that has been sanitized. * * @param elementName * The name of the XML element that has been sanitized. * @return Returns a reference to this object so that method calls can be chained together. */ public SanitizationWarning withElementName(String elementName) { setElementName(elementName); 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 (getAttributeName() != null) sb.append("AttributeName: ").append(getAttributeName()).append(","); if (getElementName() != null) sb.append("ElementName: ").append(getElementName()).append(","); if (getReason() != null) sb.append("Reason: ").append(getReason()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(SanitizationWarning sanitizationWarning, ProtocolMarshaller protocolMarshaller) { if (sanitizationWarning == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(sanitizationWarning.getAttributeName(), ATTRIBUTENAME_BINDING); protocolMarshaller.marshall(sanitizationWarning.getElementName(), ELEMENTNAME_BINDING); protocolMarshaller.marshall(sanitizationWarning.getReason(), REASON_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 + ((getAttributeName() == null) ? 0 : getAttributeName().hashCode()); hashCode = prime * hashCode + ((getElementName() == null) ? 0 : getElementName().hashCode()); hashCode = prime * hashCode + ((getReason() == null) ? 0 : getReason().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SanitizationWarning == false) return false; SanitizationWarning other = (SanitizationWarning) obj; if (other.getAttributeName() == null ^ this.getAttributeName() == null) return false; if (other.getAttributeName() != null && other.getAttributeName().equals(this.getAttributeName()) == false) return false; if (other.getElementName() == null ^ this.getElementName() == null) return false; if (other.getElementName() != null && other.getElementName().equals(this.getElementName()) == false) return false; if (other.getReason() == null ^ this.getReason() == null) return false; if (other.getReason() != null && other.getReason().equals(this.getReason()) == 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 (getAttributeName() != null) sb.append("AttributeName: ").append(getAttributeName()).append(","); if (getElementName() != null) sb.append("ElementName: ").append(getElementName()).append(","); if (getReason() != null) sb.append("Reason: ").append(getReason()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(SanitizationWarning sanitizationWarning, ProtocolMarshaller protocolMarshaller) { if (sanitizationWarning == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(sanitizationWarning.getAttributeName(), ATTRIBUTENAME_BINDING); protocolMarshaller.marshall(sanitizationWarning.getElementName(), ELEMENTNAME_BINDING); protocolMarshaller.marshall(sanitizationWarning.getReason(), REASON_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }