@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSecurityProfileIdentifier() == null) ? 0 : getSecurityProfileIdentifier().hashCode()); hashCode = prime * hashCode + ((getTarget() == null) ? 0 : getTarget().hashCode()); return hashCode; }
/** * <p> * The ARN of the security profile. * </p> * * @param arn * The ARN of the security profile. * @return Returns a reference to this object so that method calls can be chained together. */ public SecurityProfileTarget withArn(String arn) { setArn(arn); return this; }
public SecurityProfileTarget unmarshall(JsonUnmarshallerContext context) throws Exception { SecurityProfileTarget securityProfileTarget = new SecurityProfileTarget(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) { return null; } while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("arn", targetDepth)) { context.nextToken(); securityProfileTarget.setArn(context.getUnmarshaller(String.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return securityProfileTarget; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTargetMapping == false) return false; SecurityProfileTargetMapping other = (SecurityProfileTargetMapping) obj; if (other.getSecurityProfileIdentifier() == null ^ this.getSecurityProfileIdentifier() == null) return false; if (other.getSecurityProfileIdentifier() != null && other.getSecurityProfileIdentifier().equals(this.getSecurityProfileIdentifier()) == false) return false; if (other.getTarget() == null ^ this.getTarget() == null) return false; if (other.getTarget() != null && other.getTarget().equals(this.getTarget()) == false) return false; return true; }
public SecurityProfileTarget unmarshall(JsonUnmarshallerContext context) throws Exception { AwsJsonReader reader = context.getReader(); if (!reader.isContainer()) { reader.skipValue(); return null; } SecurityProfileTarget securityProfileTarget = new SecurityProfileTarget(); reader.beginObject(); while (reader.hasNext()) { String name = reader.nextName(); if (name.equals("arn")) { securityProfileTarget.setArn(StringJsonUnmarshaller.getInstance() .unmarshall(context)); } else { reader.skipValue(); } } reader.endObject(); return securityProfileTarget; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTargetMapping == false) return false; SecurityProfileTargetMapping other = (SecurityProfileTargetMapping) obj; if (other.getSecurityProfileIdentifier() == null ^ this.getSecurityProfileIdentifier() == null) return false; if (other.getSecurityProfileIdentifier() != null && other.getSecurityProfileIdentifier().equals(this.getSecurityProfileIdentifier()) == false) return false; if (other.getTarget() == null ^ this.getTarget() == null) return false; if (other.getTarget() != null && other.getTarget().equals(this.getTarget()) == false) return false; return true; } }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTarget == false) return false; SecurityProfileTarget other = (SecurityProfileTarget) obj; if (other.getArn() == null ^ this.getArn() == null) return false; if (other.getArn() != null && other.getArn().equals(this.getArn()) == false) return false; return true; }
public SecurityProfileTarget unmarshall(JsonUnmarshallerContext context) throws Exception { AwsJsonReader reader = context.getReader(); if (!reader.isContainer()) { reader.skipValue(); return null; } SecurityProfileTarget securityProfileTarget = new SecurityProfileTarget(); reader.beginObject(); while (reader.hasNext()) { String name = reader.nextName(); if (name.equals("arn")) { securityProfileTarget.setArn(StringJsonUnmarshaller.getInstance() .unmarshall(context)); } else { reader.skipValue(); } } reader.endObject(); return securityProfileTarget; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSecurityProfileIdentifier() == null) ? 0 : getSecurityProfileIdentifier() .hashCode()); hashCode = prime * hashCode + ((getTarget() == null) ? 0 : getTarget().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTargetMapping == false) return false; SecurityProfileTargetMapping other = (SecurityProfileTargetMapping) obj; if (other.getSecurityProfileIdentifier() == null ^ this.getSecurityProfileIdentifier() == null) return false; if (other.getSecurityProfileIdentifier() != null && other.getSecurityProfileIdentifier().equals(this.getSecurityProfileIdentifier()) == false) return false; if (other.getTarget() == null ^ this.getTarget() == null) return false; if (other.getTarget() != null && other.getTarget().equals(this.getTarget()) == false) return false; return true; }
/** * <p> * The ARN of the security profile. * </p> * * @param arn * The ARN of the security profile. * @return Returns a reference to this object so that method calls can be chained together. */ public SecurityProfileTarget withArn(String arn) { setArn(arn); 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 (getArn() != null) sb.append("Arn: ").append(getArn()); sb.append("}"); return sb.toString(); }
public SecurityProfileTarget unmarshall(JsonUnmarshallerContext context) throws Exception { SecurityProfileTarget securityProfileTarget = new SecurityProfileTarget(); int originalDepth = context.getCurrentDepth(); String currentParentElement = context.getCurrentParentElement(); int targetDepth = originalDepth + 1; JsonToken token = context.getCurrentToken(); if (token == null) token = context.nextToken(); if (token == VALUE_NULL) { return null; } while (true) { if (token == null) break; if (token == FIELD_NAME || token == START_OBJECT) { if (context.testExpression("arn", targetDepth)) { context.nextToken(); securityProfileTarget.setArn(context.getUnmarshaller(String.class).unmarshall(context)); } } else if (token == END_ARRAY || token == END_OBJECT) { if (context.getLastParsedParentElement() == null || context.getLastParsedParentElement().equals(currentParentElement)) { if (context.getCurrentDepth() <= originalDepth) break; } } token = context.nextToken(); } return securityProfileTarget; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getSecurityProfileIdentifier() == null) ? 0 : getSecurityProfileIdentifier().hashCode()); hashCode = prime * hashCode + ((getTarget() == null) ? 0 : getTarget().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTargetMapping == false) return false; SecurityProfileTargetMapping other = (SecurityProfileTargetMapping) obj; if (other.getSecurityProfileIdentifier() == null ^ this.getSecurityProfileIdentifier() == null) return false; if (other.getSecurityProfileIdentifier() != null && other.getSecurityProfileIdentifier().equals(this.getSecurityProfileIdentifier()) == false) return false; if (other.getTarget() == null ^ this.getTarget() == null) return false; if (other.getTarget() != null && other.getTarget().equals(this.getTarget()) == false) return false; return true; } }
/** * Marshall the given parameter object. */ public void marshall(SecurityProfileTarget securityProfileTarget, ProtocolMarshaller protocolMarshaller) { if (securityProfileTarget == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(securityProfileTarget.getArn(), ARN_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 + ((getSecurityProfileIdentifier() == null) ? 0 : getSecurityProfileIdentifier() .hashCode()); hashCode = prime * hashCode + ((getTarget() == null) ? 0 : getTarget().hashCode()); return hashCode; }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof SecurityProfileTarget == false) return false; SecurityProfileTarget other = (SecurityProfileTarget) obj; if (other.getArn() == null ^ this.getArn() == null) return false; if (other.getArn() != null && other.getArn().equals(this.getArn()) == false) return false; return true; } }