public abstract class BaseNodesResponse<TNodeResponse extends BaseNodeResponse> extends ActionResponse
TransportResponse.Empty| Modifier | Constructor and Description |
|---|---|
protected |
BaseNodesResponse() |
protected |
BaseNodesResponse(ClusterName clusterName,
java.util.List<TNodeResponse> nodes,
java.util.List<FailedNodeException> failures) |
| Modifier and Type | Method and Description |
|---|---|
java.util.List<FailedNodeException> |
failures()
Get the failed node exceptions.
|
ClusterName |
getClusterName()
Get the
ClusterName associated with all of the nodes. |
java.util.List<TNodeResponse> |
getNodes()
Get the successful node responses.
|
java.util.Map<java.lang.String,TNodeResponse> |
getNodesMap()
Lazily build and get a map of Node ID to node response.
|
boolean |
hasFailures()
Determine if there are any node failures in
failures. |
void |
readFrom(StreamInput in)
Set this object's fields from a StreamInput.
|
protected abstract java.util.List<TNodeResponse> |
readNodesFrom(StreamInput in)
Read the
nodes from the stream. |
protected abstract void |
writeNodesTo(StreamOutput out,
java.util.List<TNodeResponse> nodes)
Write the
nodes to the stream. |
void |
writeTo(StreamOutput out)
Write this object's fields to a StreamOutput.
|
remoteAddress, remoteAddressprotected BaseNodesResponse()
protected BaseNodesResponse(ClusterName clusterName, java.util.List<TNodeResponse> nodes, java.util.List<FailedNodeException> failures)
public ClusterName getClusterName()
ClusterName associated with all of the nodes.null.public java.util.List<FailedNodeException> failures()
null. Can be empty.public boolean hasFailures()
failures.true if failures contains at least 1 FailedNodeException.public java.util.List<TNodeResponse> getNodes()
null. Can be empty.hasFailures()public java.util.Map<java.lang.String,TNodeResponse> getNodesMap()
null. Can be empty.getNodes()public void readFrom(StreamInput in) throws java.io.IOException
StreamablereadFrom in interface StreamablereadFrom in class ActionResponsejava.io.IOExceptionpublic void writeTo(StreamOutput out) throws java.io.IOException
StreamablewriteTo in interface StreamablewriteTo in class ActionResponsejava.io.IOExceptionprotected abstract java.util.List<TNodeResponse> readNodesFrom(StreamInput in) throws java.io.IOException
nodes from the stream.null.java.io.IOExceptionprotected abstract void writeNodesTo(StreamOutput out, java.util.List<TNodeResponse> nodes) throws java.io.IOException
nodes to the stream.java.io.IOException