Module org.elasticsearch.server
Class IndicesAliasesResponse.AliasActionResult
java.lang.Object
org.elasticsearch.action.admin.indices.alias.IndicesAliasesResponse.AliasActionResult
- All Implemented Interfaces:
Writeable,ToXContent,ToXContentObject
- Enclosing class:
IndicesAliasesResponse
public static class IndicesAliasesResponse.AliasActionResult
extends Object
implements Writeable, ToXContentObject
Result for a single alias add/remove action
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.elasticsearch.xcontent.ToXContent
ToXContent.DelegatingMapParams, ToXContent.MapParams, ToXContent.ParamsNested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable
Writeable.Reader<V>, Writeable.Writer<V> -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final Stringstatic final StringFields inherited from interface org.elasticsearch.xcontent.ToXContent
EMPTY, EMPTY_PARAMS -
Method Summary
Modifier and TypeMethodDescriptionbuild(List<String> indices, IndicesAliasesRequest.AliasActions action, int numAliasesRemoved) Build result that could be either a success or failurebuildSuccess(List<String> indices, IndicesAliasesRequest.AliasActions action) Build a success action result with no errors.booleangetError()The error result if the action failed, null if the action succeeded.inthashCode()toXContent(XContentBuilder builder, ToXContent.Params params) voidwriteTo(StreamOutput out) Write this into the StreamOutput.Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.elasticsearch.xcontent.ToXContentObject
isFragment
-
Field Details
-
ACTION_FIELD
- See Also:
-
ACTION_TYPE_FIELD
- See Also:
-
ACTION_INDICES_FIELD
- See Also:
-
ACTION_ALIASES_FIELD
- See Also:
-
STATUS_FIELD
- See Also:
-
ERROR_FIELD
- See Also:
-
-
Method Details
-
build
public static IndicesAliasesResponse.AliasActionResult build(List<String> indices, IndicesAliasesRequest.AliasActions action, int numAliasesRemoved) Build result that could be either a success or failure- Parameters:
indices- the resolved indices to which the associated action appliesaction- the alias action consisting of add/remove, aliases, and indicesnumAliasesRemoved- the number of aliases remove, if any- Returns:
- the action result
-
buildSuccess
public static IndicesAliasesResponse.AliasActionResult buildSuccess(List<String> indices, IndicesAliasesRequest.AliasActions action) Build a success action result with no errors. -
getError
The error result if the action failed, null if the action succeeded. -
writeTo
Description copied from interface:WriteableWrite this into the StreamOutput.- Specified by:
writeToin interfaceWriteable- Throws:
IOException
-
toXContent
public XContentBuilder toXContent(XContentBuilder builder, ToXContent.Params params) throws IOException - Specified by:
toXContentin interfaceToXContent- Throws:
IOException
-
equals
-
hashCode
public int hashCode()
-