@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getResourceChange() == null) ? 0 : getResourceChange().hashCode()); return hashCode; }
/** * <p> * A <code>ResourceChange</code> structure that describes the resource and action that AWS CloudFormation will * perform. * </p> * * @param resourceChange * A <code>ResourceChange</code> structure that describes the resource and action that AWS CloudFormation * will perform. * @return Returns a reference to this object so that method calls can be chained together. */ public Change withResourceChange(ResourceChange resourceChange) { setResourceChange(resourceChange); return this; }
/** * <p> * The type of entity that AWS CloudFormation changes. Currently, the only entity type is <code>Resource</code>. * </p> * * @param type * The type of entity that AWS CloudFormation changes. Currently, the only entity type is * <code>Resource</code>. * @return Returns a reference to this object so that method calls can be chained together. * @see ChangeType */ public Change withType(String type) { setType(type); return this; }
public Change unmarshall(StaxUnmarshallerContext context) throws Exception { Change change = new Change(); int originalDepth = context.getCurrentDepth(); int targetDepth = originalDepth + 1; if (context.isStartOfDocument()) targetDepth += 1; while (true) { XMLEvent xmlEvent = context.nextEvent(); if (xmlEvent.isEndDocument()) return change; if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) { if (context.testExpression("Type", targetDepth)) { change.setType(StringStaxUnmarshaller.getInstance().unmarshall(context)); continue; } if (context.testExpression("ResourceChange", targetDepth)) { change.setResourceChange(ResourceChangeStaxUnmarshaller.getInstance().unmarshall(context)); continue; } } else if (xmlEvent.isEndElement()) { if (context.getCurrentDepth() < originalDepth) { return change; } } } }
/** * <p> * The type of entity that AWS CloudFormation changes. Currently, the only entity type is <code>Resource</code>. * </p> * * @param type * The type of entity that AWS CloudFormation changes. Currently, the only entity type is * <code>Resource</code>. * @see ChangeType */ public void setType(ChangeType type) { withType(type); }
public Change unmarshall(StaxUnmarshallerContext context) throws Exception { Change change = new Change(); int originalDepth = context.getCurrentDepth(); int targetDepth = originalDepth + 1; if (context.isStartOfDocument()) targetDepth += 1; while (true) { XMLEvent xmlEvent = context.nextEvent(); if (xmlEvent.isEndDocument()) return change; if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) { if (context.testExpression("Type", targetDepth)) { change.setType(StringStaxUnmarshaller.getInstance().unmarshall(context)); continue; } if (context.testExpression("ResourceChange", targetDepth)) { change.setResourceChange(ResourceChangeStaxUnmarshaller.getInstance().unmarshall(context)); continue; } } else if (xmlEvent.isEndElement()) { if (context.getCurrentDepth() < originalDepth) { return change; } } } }
/** * <p> * The type of entity that AWS CloudFormation changes. Currently, the only entity type is <code>Resource</code>. * </p> * * @param type * The type of entity that AWS CloudFormation changes. Currently, the only entity type is * <code>Resource</code>. * @see ChangeType */ public void setType(ChangeType type) { withType(type); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof Change == false) return false; Change other = (Change) obj; if (other.getType() == null ^ this.getType() == null) return false; if (other.getType() != null && other.getType().equals(this.getType()) == false) return false; if (other.getResourceChange() == null ^ this.getResourceChange() == null) return false; if (other.getResourceChange() != null && other.getResourceChange().equals(this.getResourceChange()) == false) return false; return true; }
/** * <p> * The type of entity that AWS CloudFormation changes. Currently, the only entity type is <code>Resource</code>. * </p> * * @param type * The type of entity that AWS CloudFormation changes. Currently, the only entity type is * <code>Resource</code>. * @return Returns a reference to this object so that method calls can be chained together. * @see ChangeType */ public Change withType(String type) { setType(type); return this; }
/** * <p> * A <code>ResourceChange</code> structure that describes the resource and action that AWS CloudFormation will * perform. * </p> * * @param resourceChange * A <code>ResourceChange</code> structure that describes the resource and action that AWS CloudFormation * will perform. * @return Returns a reference to this object so that method calls can be chained together. */ public Change withResourceChange(ResourceChange resourceChange) { setResourceChange(resourceChange); 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 (getType() != null) sb.append("Type: ").append(getType()).append(","); if (getResourceChange() != null) sb.append("ResourceChange: ").append(getResourceChange()); sb.append("}"); return sb.toString(); }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getResourceChange() == null) ? 0 : getResourceChange().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof Change == false) return false; Change other = (Change) obj; if (other.getType() == null ^ this.getType() == null) return false; if (other.getType() != null && other.getType().equals(this.getType()) == false) return false; if (other.getResourceChange() == null ^ this.getResourceChange() == null) return false; if (other.getResourceChange() != null && other.getResourceChange().equals(this.getResourceChange()) == 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 (getType() != null) sb.append("Type: ").append(getType()).append(","); if (getResourceChange() != null) sb.append("ResourceChange: ").append(getResourceChange()); sb.append("}"); return sb.toString(); }