@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAction() == null) ? 0 : getAction().hashCode()); hashCode = prime * hashCode + ((getIPSetDescriptor() == null) ? 0 : getIPSetDescriptor().hashCode()); return hashCode; }
/** * <p> * Specifies whether to insert or delete an IP address with <a>UpdateIPSet</a>. * </p> * * @param action * Specifies whether to insert or delete an IP address with <a>UpdateIPSet</a>. * @return Returns a reference to this object so that method calls can be chained together. * @see ChangeAction */ public IPSetUpdate withAction(String action) { setAction(action); return this; }
/** * <p> * The IP address type (<code>IPV4</code> or <code>IPV6</code>) and the IP address range (in CIDR notation) that web * requests originate from. * </p> * * @param iPSetDescriptor * The IP address type (<code>IPV4</code> or <code>IPV6</code>) and the IP address range (in CIDR notation) * that web requests originate from. * @return Returns a reference to this object so that method calls can be chained together. */ public IPSetUpdate withIPSetDescriptor(IPSetDescriptor iPSetDescriptor) { setIPSetDescriptor(iPSetDescriptor); return this; }
public IPSetUpdate unmarshall(JsonUnmarshallerContext context) throws Exception { IPSetUpdate iPSetUpdate = new IPSetUpdate(); if (context.testExpression("Action", targetDepth)) { context.nextToken(); iPSetUpdate.setAction(context.getUnmarshaller(String.class).unmarshall(context)); iPSetUpdate.setIPSetDescriptor(IPSetDescriptorJsonUnmarshaller.getInstance().unmarshall(context));
/** * <p> * Specifies whether to insert or delete an IP address with <a>UpdateIPSet</a>. * </p> * * @param action * Specifies whether to insert or delete an IP address with <a>UpdateIPSet</a>. * @see ChangeAction */ public void setAction(ChangeAction action) { withAction(action); }
public IPSetUpdate unmarshall(JsonUnmarshallerContext context) throws Exception { IPSetUpdate iPSetUpdate = new IPSetUpdate(); if (context.testExpression("Action", targetDepth)) { context.nextToken(); iPSetUpdate.setAction(context.getUnmarshaller(String.class).unmarshall(context)); iPSetUpdate.setIPSetDescriptor(IPSetDescriptorJsonUnmarshaller.getInstance().unmarshall(context));
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof IPSetUpdate == false) return false; IPSetUpdate other = (IPSetUpdate) obj; if (other.getAction() == null ^ this.getAction() == null) return false; if (other.getAction() != null && other.getAction().equals(this.getAction()) == false) return false; if (other.getIPSetDescriptor() == null ^ this.getIPSetDescriptor() == null) return false; if (other.getIPSetDescriptor() != null && other.getIPSetDescriptor().equals(this.getIPSetDescriptor()) == 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 (getAction() != null) sb.append("Action: ").append(getAction()).append(","); if (getIPSetDescriptor() != null) sb.append("IPSetDescriptor: ").append(getIPSetDescriptor()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(IPSetUpdate iPSetUpdate, ProtocolMarshaller protocolMarshaller) { if (iPSetUpdate == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(iPSetUpdate.getAction(), ACTION_BINDING); protocolMarshaller.marshall(iPSetUpdate.getIPSetDescriptor(), IPSETDESCRIPTOR_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
/** * Marshall the given parameter object. */ public void marshall(IPSetUpdate iPSetUpdate, ProtocolMarshaller protocolMarshaller) { if (iPSetUpdate == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(iPSetUpdate.getAction(), ACTION_BINDING); protocolMarshaller.marshall(iPSetUpdate.getIPSetDescriptor(), IPSETDESCRIPTOR_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }