
com.plivo.api.models.multipartycall.MultiPartyCallList Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of plivo-java Show documentation
Show all versions of plivo-java Show documentation
A Java SDK to make voice calls & send SMS using Plivo and to generate Plivo XML
package com.plivo.api.models.multipartycall;
import com.plivo.api.exceptions.PlivoValidationException;
import com.plivo.api.models.base.ListResponse;
import com.plivo.api.models.base.VoiceLister;
import com.plivo.api.util.PropertyFilter;
import com.plivo.api.validators.OneOf;
import com.plivo.api.validators.SubAccount;
import com.plivo.api.validators.Validate;
import retrofit2.Call;
public class MultiPartyCallList extends VoiceLister {
@SubAccount
private String subAccount;
private String friendlyName;
@OneOf(message = "should be one of [initialized, active, ended]", options = {"initialized", "active", "ended"})
private String status;
private Integer terminationCauseCode;
private PropertyFilter creationTime;
private PropertyFilter endTime;
public String subAccount() {
return subAccount;
}
public String friendlyName() {
return friendlyName;
}
public String status() {
return status;
}
public Integer terminationCauseCode() {
return terminationCauseCode;
}
public PropertyFilter creationTime() {
return creationTime;
}
public PropertyFilter endTime() {
return endTime;
}
public MultiPartyCallList subAccount(String subAccount) {
this.subAccount = subAccount;
return this;
}
public MultiPartyCallList friendlyName(String friendlyName) {
this.friendlyName = friendlyName;
return this;
}
public MultiPartyCallList status(String status) {
this.status = status;
return this;
}
public MultiPartyCallList terminationCauseCode(Integer terminationCauseCode) {
this.terminationCauseCode = terminationCauseCode;
return this;
}
public MultiPartyCallList creationTime(PropertyFilter creationTime) throws PlivoValidationException {
MultiPartyCallUtils.validMultiPartyTime("creationTime", creationTime);
this.creationTime = creationTime;
return this;
}
public MultiPartyCallList endTime(PropertyFilter endTime) throws PlivoValidationException {
MultiPartyCallUtils.validMultiPartyTime("endTime", endTime);
this.endTime = endTime;
return this;
}
@Override
protected Call> obtainCall() throws PlivoValidationException {
Validate.check(this);
return client().getVoiceApiService().mpcList(client().getAuthId(), toMap());
}
@Override
protected Call> obtainFallback1Call() throws PlivoValidationException {
Validate.check(this);
return client().getVoiceFallback1Service().mpcList(client().getAuthId(), toMap());
}
@Override
protected Call> obtainFallback2Call() throws PlivoValidationException {
Validate.check(this);
return client().getVoiceFallback2Service().mpcList(client().getAuthId(), toMap());
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy