setName(name); return this;
/** * <p> * For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is * healthy, the region that the alarm was created in. * </p> * <p> * For the current list of CloudWatch regions, see <a * href="http://docs.aws.amazon.com/general/latest/gr/rande.html#cw_region">Amazon CloudWatch</a> in the <i>AWS * Regions and Endpoints</i> chapter of the <i>Amazon Web Services General Reference</i>. * </p> * * @param region * For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health * check is healthy, the region that the alarm was created in.</p> * <p> * For the current list of CloudWatch regions, see <a * href="http://docs.aws.amazon.com/general/latest/gr/rande.html#cw_region">Amazon CloudWatch</a> in the * <i>AWS Regions and Endpoints</i> chapter of the <i>Amazon Web Services General Reference</i>. * @return Returns a reference to this object so that method calls can be chained together. * @see CloudWatchRegion */ public AlarmIdentifier withRegion(String region) { setRegion(region); return this; }
public AlarmIdentifier unmarshall(StaxUnmarshallerContext context) throws Exception { AlarmIdentifier alarmIdentifier = new AlarmIdentifier(); int originalDepth = context.getCurrentDepth(); int targetDepth = originalDepth + 1; if (context.isStartOfDocument()) targetDepth += 1; while (true) { XMLEvent xmlEvent = context.nextEvent(); if (xmlEvent.isEndDocument()) return alarmIdentifier; if (xmlEvent.isAttribute() || xmlEvent.isStartElement()) { if (context.testExpression("Region", targetDepth)) { alarmIdentifier.setRegion(StringStaxUnmarshaller.getInstance().unmarshall(context)); continue; } if (context.testExpression("Name", targetDepth)) { alarmIdentifier.setName(StringStaxUnmarshaller.getInstance().unmarshall(context)); continue; } } else if (xmlEvent.isEndElement()) { if (context.getCurrentDepth() < originalDepth) { return alarmIdentifier; } } } }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getHealthCheckId() == null) ? 0 : getHealthCheckId().hashCode()); hashCode = prime * hashCode + ((getHealthCheckVersion() == null) ? 0 : getHealthCheckVersion().hashCode()); hashCode = prime * hashCode + ((getIPAddress() == null) ? 0 : getIPAddress().hashCode()); hashCode = prime * hashCode + ((getPort() == null) ? 0 : getPort().hashCode()); hashCode = prime * hashCode + ((getResourcePath() == null) ? 0 : getResourcePath().hashCode()); hashCode = prime * hashCode + ((getFullyQualifiedDomainName() == null) ? 0 : getFullyQualifiedDomainName().hashCode()); hashCode = prime * hashCode + ((getSearchString() == null) ? 0 : getSearchString().hashCode()); hashCode = prime * hashCode + ((getFailureThreshold() == null) ? 0 : getFailureThreshold().hashCode()); hashCode = prime * hashCode + ((getInverted() == null) ? 0 : getInverted().hashCode()); hashCode = prime * hashCode + ((getDisabled() == null) ? 0 : getDisabled().hashCode()); hashCode = prime * hashCode + ((getHealthThreshold() == null) ? 0 : getHealthThreshold().hashCode()); hashCode = prime * hashCode + ((getChildHealthChecks() == null) ? 0 : getChildHealthChecks().hashCode()); hashCode = prime * hashCode + ((getEnableSNI() == null) ? 0 : getEnableSNI().hashCode()); hashCode = prime * hashCode + ((getRegions() == null) ? 0 : getRegions().hashCode()); hashCode = prime * hashCode + ((getAlarmIdentifier() == null) ? 0 : getAlarmIdentifier().hashCode()); hashCode = prime * hashCode + ((getInsufficientDataHealthStatus() == null) ? 0 : getInsufficientDataHealthStatus().hashCode()); hashCode = prime * hashCode + ((getResetElements() == null) ? 0 : getResetElements().hashCode()); return hashCode; }
if (other.getAlarmIdentifier() == null ^ this.getAlarmIdentifier() == null) return false; if (other.getAlarmIdentifier() != null && other.getAlarmIdentifier().equals(this.getAlarmIdentifier()) == false) return false; if (other.getInsufficientDataHealthStatus() == null ^ this.getInsufficientDataHealthStatus() == null)
/** * <p> * For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health check is * healthy, the region that the alarm was created in. * </p> * <p> * For the current list of CloudWatch regions, see <a * href="http://docs.aws.amazon.com/general/latest/gr/rande.html#cw_region">Amazon CloudWatch</a> in the <i>AWS * Regions and Endpoints</i> chapter of the <i>Amazon Web Services General Reference</i>. * </p> * * @param region * For the CloudWatch alarm that you want Route 53 health checkers to use to determine whether this health * check is healthy, the region that the alarm was created in.</p> * <p> * For the current list of CloudWatch regions, see <a * href="http://docs.aws.amazon.com/general/latest/gr/rande.html#cw_region">Amazon CloudWatch</a> in the * <i>AWS Regions and Endpoints</i> chapter of the <i>Amazon Web Services General Reference</i>. * @see CloudWatchRegion */ public void setRegion(CloudWatchRegion region) { withRegion(region); }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getIPAddress() == null) ? 0 : getIPAddress().hashCode()); hashCode = prime * hashCode + ((getPort() == null) ? 0 : getPort().hashCode()); hashCode = prime * hashCode + ((getType() == null) ? 0 : getType().hashCode()); hashCode = prime * hashCode + ((getResourcePath() == null) ? 0 : getResourcePath().hashCode()); hashCode = prime * hashCode + ((getFullyQualifiedDomainName() == null) ? 0 : getFullyQualifiedDomainName().hashCode()); hashCode = prime * hashCode + ((getSearchString() == null) ? 0 : getSearchString().hashCode()); hashCode = prime * hashCode + ((getRequestInterval() == null) ? 0 : getRequestInterval().hashCode()); hashCode = prime * hashCode + ((getFailureThreshold() == null) ? 0 : getFailureThreshold().hashCode()); hashCode = prime * hashCode + ((getMeasureLatency() == null) ? 0 : getMeasureLatency().hashCode()); hashCode = prime * hashCode + ((getInverted() == null) ? 0 : getInverted().hashCode()); hashCode = prime * hashCode + ((getDisabled() == null) ? 0 : getDisabled().hashCode()); hashCode = prime * hashCode + ((getHealthThreshold() == null) ? 0 : getHealthThreshold().hashCode()); hashCode = prime * hashCode + ((getChildHealthChecks() == null) ? 0 : getChildHealthChecks().hashCode()); hashCode = prime * hashCode + ((getEnableSNI() == null) ? 0 : getEnableSNI().hashCode()); hashCode = prime * hashCode + ((getRegions() == null) ? 0 : getRegions().hashCode()); hashCode = prime * hashCode + ((getAlarmIdentifier() == null) ? 0 : getAlarmIdentifier().hashCode()); hashCode = prime * hashCode + ((getInsufficientDataHealthStatus() == null) ? 0 : getInsufficientDataHealthStatus().hashCode()); return hashCode; }
if (other.getAlarmIdentifier() == null ^ this.getAlarmIdentifier() == null) return false; if (other.getAlarmIdentifier() != null && other.getAlarmIdentifier().equals(this.getAlarmIdentifier()) == false) return false; if (other.getInsufficientDataHealthStatus() == null ^ this.getInsufficientDataHealthStatus() == null)
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof AlarmIdentifier == false) return false; AlarmIdentifier other = (AlarmIdentifier) obj; if (other.getRegion() == null ^ this.getRegion() == null) return false; if (other.getRegion() != null && other.getRegion().equals(this.getRegion()) == false) return false; if (other.getName() == null ^ this.getName() == null) return false; if (other.getName() != null && other.getName().equals(this.getName()) == 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 (getRegion() != null) sb.append("Region: ").append(getRegion()).append(","); if (getName() != null) sb.append("Name: ").append(getName()); sb.append("}"); return sb.toString(); }