com.ksc.network.vpc.model.Nat.DescribeNatsRequest Maven / Gradle / Ivy
package com.ksc.network.vpc.model.Nat;
import com.ksc.KscWebServiceRequest;
import com.ksc.Request;
import com.ksc.model.DryRunSupportedRequest;
import com.ksc.model.Filter;
import lombok.ToString;
/**
*
* Contains the parameters for DescribeNats.
*
*/
@ToString
public class DescribeNatsRequest extends KscWebServiceRequest implements
DryRunSupportedRequest {
private com.ksc.internal.SdkInternalList natIds;
private com.ksc.internal.SdkInternalList filters;
public java.util.List getNatIds() {
if (natIds == null) {
natIds = new com.ksc.internal.SdkInternalList();
}
return natIds;
}
public void setNatIds(java.util.Collection natIds) {
if (natIds == null) {
this.natIds = null;
return;
}
this.natIds = new com.ksc.internal.SdkInternalList(natIds);
}
public DescribeNatsRequest withNatIds(String... natIds) {
if (this.natIds == null) {
setNatIds(new com.ksc.internal.SdkInternalList(
natIds.length));
}
for (String ele : natIds) {
this.natIds.add(ele);
}
return this;
}
public DescribeNatsRequest withNatIds(java.util.Collection natIds) {
setNatIds(natIds);
return this;
}
public java.util.List getFilters() {
if (filters == null) {
filters = new com.ksc.internal.SdkInternalList();
}
return filters;
}
public void setFilters(java.util.Collection filters) {
if (filters == null) {
this.filters = null;
return;
}
this.filters = new com.ksc.internal.SdkInternalList(
filters);
}
public DescribeNatsRequest withFilters(Filter... filters) {
if (this.filters == null) {
setFilters(new com.ksc.internal.SdkInternalList(
filters.length));
}
for (Filter ele : filters) {
this.filters.add(ele);
}
return this;
}
public DescribeNatsRequest withFilters(java.util.Collection filters) {
setFilters(filters);
return this;
}
@Override
public boolean equals(Object o) {
if (this == o) return true;
if (o == null || getClass() != o.getClass()) return false;
DescribeNatsRequest that = (DescribeNatsRequest) o;
if (!natIds.equals(that.natIds)) return false;
return filters.equals(that.filters);
}
@Override
public int hashCode() {
int result = natIds.hashCode();
result = 31 * result + filters.hashCode();
return result;
}
/**
* This method is intended for internal use only. Returns the marshaled
* request configured with additional parameters to enable operation
* dry-run.
*/
@Override
public Request getDryRunRequest() {
/*Request request = new DescribeSubnetsRequestMarshaller()
.marshall(this);
request.addParameter("DryRun", Boolean.toString(true));
return request;*/
return null;
}
}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy