@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getInstanceIds() == null) ? 0 : getInstanceIds().hashCode()); hashCode = prime * hashCode + ((getMaxRecords() == null) ? 0 : getMaxRecords().hashCode()); hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); return hashCode; }
/** * 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 (getInstanceIds() != null) sb.append("InstanceIds: ").append(getInstanceIds()).append(","); if (getMaxRecords() != null) sb.append("MaxRecords: ").append(getMaxRecords()).append(","); if (getNextToken() != null) sb.append("NextToken: ").append(getNextToken()); sb.append("}"); return sb.toString(); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DescribeAutoScalingInstancesRequest == false) return false; DescribeAutoScalingInstancesRequest other = (DescribeAutoScalingInstancesRequest) obj; if (other.getInstanceIds() == null ^ this.getInstanceIds() == null) return false; if (other.getInstanceIds() != null && other.getInstanceIds().equals(this.getInstanceIds()) == false) return false; if (other.getMaxRecords() == null ^ this.getMaxRecords() == null) return false; if (other.getMaxRecords() != null && other.getMaxRecords().equals(this.getMaxRecords()) == false) return false; if (other.getNextToken() == null ^ this.getNextToken() == null) return false; if (other.getNextToken() != null && other.getNextToken().equals(this.getNextToken()) == false) return false; return true; }
public Request<DescribeAutoScalingInstancesRequest> marshall(DescribeAutoScalingInstancesRequest describeAutoScalingInstancesRequest) { if (describeAutoScalingInstancesRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } Request<DescribeAutoScalingInstancesRequest> request = new DefaultRequest<DescribeAutoScalingInstancesRequest>(describeAutoScalingInstancesRequest, "AmazonAutoScaling"); request.addParameter("Action", "DescribeAutoScalingInstances"); request.addParameter("Version", "2011-01-01"); request.setHttpMethod(HttpMethodName.POST); if (!describeAutoScalingInstancesRequest.getInstanceIds().isEmpty() || !((com.amazonaws.internal.SdkInternalList<String>) describeAutoScalingInstancesRequest.getInstanceIds()).isAutoConstruct()) { com.amazonaws.internal.SdkInternalList<String> instanceIdsList = (com.amazonaws.internal.SdkInternalList<String>) describeAutoScalingInstancesRequest .getInstanceIds(); int instanceIdsListIndex = 1; for (String instanceIdsListValue : instanceIdsList) { if (instanceIdsListValue != null) { request.addParameter("InstanceIds.member." + instanceIdsListIndex, StringUtils.fromString(instanceIdsListValue)); } instanceIdsListIndex++; } } if (describeAutoScalingInstancesRequest.getMaxRecords() != null) { request.addParameter("MaxRecords", StringUtils.fromInteger(describeAutoScalingInstancesRequest.getMaxRecords())); } if (describeAutoScalingInstancesRequest.getNextToken() != null) { request.addParameter("NextToken", StringUtils.fromString(describeAutoScalingInstancesRequest.getNextToken())); } return request; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getInstanceIds() == null) ? 0 : getInstanceIds().hashCode()); hashCode = prime * hashCode + ((getMaxRecords() == null) ? 0 : getMaxRecords().hashCode()); hashCode = prime * hashCode + ((getNextToken() == null) ? 0 : getNextToken().hashCode()); return hashCode; }
/** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getInstanceIds() != null) sb.append("InstanceIds: " + getInstanceIds() + ","); if (getMaxRecords() != null) sb.append("MaxRecords: " + getMaxRecords() + ","); if (getNextToken() != null) sb.append("NextToken: " + getNextToken()); sb.append("}"); return sb.toString(); }
@Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof DescribeAutoScalingInstancesRequest == false) return false; DescribeAutoScalingInstancesRequest other = (DescribeAutoScalingInstancesRequest) obj; if (other.getInstanceIds() == null ^ this.getInstanceIds() == null) return false; if (other.getInstanceIds() != null && other.getInstanceIds().equals(this.getInstanceIds()) == false) return false; if (other.getMaxRecords() == null ^ this.getMaxRecords() == null) return false; if (other.getMaxRecords() != null && other.getMaxRecords().equals(this.getMaxRecords()) == false) return false; if (other.getNextToken() == null ^ this.getNextToken() == null) return false; if (other.getNextToken() != null && other.getNextToken().equals(this.getNextToken()) == false) return false; return true; } }
request.addParameter(prefix, StringUtils.fromInteger(maxRecords)); if (describeAutoScalingInstancesRequest.getNextToken() != null) { prefix = "NextToken"; String nextToken = describeAutoScalingInstancesRequest.getNextToken(); request.addParameter(prefix, StringUtils.fromString(nextToken));