com.voximplant.apiclient.response.GetPhoneNumbersResponse Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of apiclient Show documentation
Show all versions of apiclient Show documentation
Voximplant Java API client library. Voximplant is a cloud communications platform for business and developers
package com.voximplant.apiclient.response;
import java.util.Arrays;
import java.util.Date;
import java.util.Map;
import java.math.BigDecimal;
import com.voximplant.apiclient.util.MultiArgument;
import com.voximplant.apiclient.util.Error;
import com.fasterxml.jackson.databind.annotation.JsonDeserialize;
import com.voximplant.apiclient.util.StringHelper;
import com.voximplant.apiclient.util.Alignable;
public class GetPhoneNumbersResponse implements Alignable {
private Error error;
public Error getError() {
return error;
}
public boolean hasError() {
return this.error != null;
}
private AttachedPhoneInfoType[] result;
/**
* Phone numbers info
*/
public AttachedPhoneInfoType[] getResult() {
return this.result;
}
public boolean hasResult() {
return this.result != null;
}
private Long totalCount;
/**
* The total found phone count
*/
public Long getTotalCount() {
return this.totalCount;
}
public boolean hasTotalCount() {
return this.totalCount != null;
}
private Long count;
/**
* The returned phone count
*/
public Long getCount() {
return this.count;
}
public boolean hasCount() {
return this.count != null;
}
public String toString(int alignment) {
char[] preAligned = new char[alignment - 1];
char[] aligned = new char[alignment];
Arrays.fill(preAligned, '\t');
Arrays.fill(aligned, '\t');
StringBuilder sb = new StringBuilder()
.append(preAligned)
.append('{')
.append(System.lineSeparator());
if (result != null) {
sb.append(aligned)
.append("\"AttachedPhoneInfoType\": ")
.append(StringHelper.arrayToString(result, alignment + 1))
.append(System.lineSeparator());
}
if (totalCount != null) {
sb.append(aligned)
.append("\"totalCount\": \"")
.append(totalCount)
.append('"')
.append(',')
.append(System.lineSeparator());
}
if (count != null) {
sb.append(aligned)
.append("\"count\": \"")
.append(count)
.append('"')
.append(',')
.append(System.lineSeparator());
}
return sb.append(preAligned).append('}').append(',').toString();
}
@Override
public String toString() {
return toString(1);
}}
© 2015 - 2024 Weber Informatics LLC | Privacy Policy