Class ContactListResponse
java.lang.Object
com.sinch.sdk.core.models.pagination.ListResponse<Contact>
com.sinch.sdk.domains.conversation.models.v1.contact.response.ContactListResponse
Lists all contacts
- Since:
- 1.0
-
Constructor Summary
ConstructorDescriptionContactListResponse
(ContactService service, com.sinch.sdk.core.models.pagination.Page<ContactListRequest, Contact, String> page) Create paginated list response for Contacts -
Method Summary
Methods inherited from class com.sinch.sdk.core.models.pagination.ListResponse
iterator, stream
-
Constructor Details
-
ContactListResponse
public ContactListResponse(ContactService service, com.sinch.sdk.core.models.pagination.Page<ContactListRequest, Contact, String> page) Create paginated list response for Contacts- Parameters:
service
- Service to be used to paginate across responsespage
- Page content
-
-
Method Details
-
hasNextPage
public boolean hasNextPage()Indicate if another page response is available- Specified by:
hasNextPage
in classListResponse<Contact>
- Returns:
- Returns true if the iteration has more pages. (In other words, returns true if next() would return a page rather than throwing an exception.)
-
nextPage
Get next page response if available- Specified by:
nextPage
in classListResponse<Contact>
- Returns:
- Returns the next page in the pagination/iteration. Next page response. Exception is throw in case no page available; call hasNextPage before to ensure is page is available
-
getContent
Get the page items collection content- Specified by:
getContent
in classListResponse<Contact>
- Returns:
- The items related to current page content
-
toString
-