Class PutResponse (2.0.0)

public class PutResponse implements Iterable<OperationResult>, Serializable

Represents a result of putting a list of objects (documents or queries) into an index. The response contains a list of OperationResult indicating success or not of putting each of the objects into the index, and a list of Id of the objects which are those given in the request or allocated by the search service to those objects which do not have an Id supplied.

Inheritance

java.lang.Object > PutResponse

Constructors

PutResponse(List<OperationResult> results, List<String> ids)

protected PutResponse(List<OperationResult> results, List<String> ids)

Creates a PutResponse by specifying a list of OperationResult and a list of document or query ids.

Parameters
NameDescription
resultsList<OperationResult>

a list of OperationResult that indicate the success or not putting each object into the index

idsList<String>

a list of Id of objects that were requested to be put into the index. The search service may supply Ids for those objects where none was supplied

Methods

getIds()

public List<String> getIds()
Returns
TypeDescription
List<String>

an unmodifiable list of Ids

getResults()

public List<OperationResult> getResults()
Returns
TypeDescription
List<OperationResult>

an unmodifiable list of OperationResult indicating whether each Document was put or not

iterator()

public Iterator<OperationResult> iterator()
Returns
TypeDescription
Iterator<OperationResult>

toString()

public String toString()
Returns
TypeDescription
String
Overrides