java.lang.Object
org.elasticsearch.cluster.routing.allocation.decider.Decision
org.elasticsearch.cluster.routing.allocation.decider.Decision.Multi
All Implemented Interfaces:
Writeable, org.elasticsearch.common.xcontent.ToXContent, org.elasticsearch.common.xcontent.ToXContentFragment
Enclosing class:
Decision

public static class Decision.Multi
extends Decision
implements org.elasticsearch.common.xcontent.ToXContentFragment
Simple class representing a list of decisions
  • Nested Class Summary

    Nested classes/interfaces inherited from class org.elasticsearch.cluster.routing.allocation.decider.Decision

    Decision.Multi, Decision.Single, Decision.Type

    Nested classes/interfaces inherited from interface org.elasticsearch.common.xcontent.ToXContent

    org.elasticsearch.common.xcontent.ToXContent.DelegatingMapParams, org.elasticsearch.common.xcontent.ToXContent.MapParams, org.elasticsearch.common.xcontent.ToXContent.Params

    Nested classes/interfaces inherited from interface org.elasticsearch.common.io.stream.Writeable

    Writeable.Reader<V>, Writeable.Writer<V>
  • Field Summary

    Fields inherited from class org.elasticsearch.cluster.routing.allocation.decider.Decision

    ALWAYS, NO, THROTTLE, YES

    Fields inherited from interface org.elasticsearch.common.xcontent.ToXContent

    EMPTY_PARAMS
  • Constructor Summary

    Constructors
    Constructor Description
    Multi()  
  • Method Summary

    Modifier and Type Method Description
    Decision.Multi add​(Decision decision)
    Add a decision to this Decision.Multidecision instance
    boolean equals​(java.lang.Object object)  
    java.util.List<Decision> getDecisions()
    Return the list of all decisions that make up this decision
    java.lang.String getExplanation()
    Get the explanation for this decision.
    int hashCode()  
    java.lang.String label()
    Get the description label for this decision.
    java.lang.String toString()  
    org.elasticsearch.common.xcontent.XContentBuilder toXContent​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params)  
    Decision.Type type()
    Get the Decision.Type of this decision
    void writeTo​(StreamOutput out)
    Write this into the StreamOutput.

    Methods inherited from class org.elasticsearch.cluster.routing.allocation.decider.Decision

    readFrom, single

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, wait, wait, wait

    Methods inherited from interface org.elasticsearch.common.xcontent.ToXContentFragment

    isFragment
  • Constructor Details

    • Multi

      public Multi()
  • Method Details

    • add

      public Decision.Multi add​(Decision decision)
      Add a decision to this Decision.Multidecision instance
      Parameters:
      decision - Decision to add
      Returns:
      Decision.Multidecision instance with the given decision added
    • type

      public Decision.Type type()
      Description copied from class: Decision
      Get the Decision.Type of this decision
      Specified by:
      type in class Decision
      Returns:
      Decision.Type of this decision
    • label

      @Nullable public java.lang.String label()
      Description copied from class: Decision
      Get the description label for this decision.
      Specified by:
      label in class Decision
    • getExplanation

      @Nullable public java.lang.String getExplanation()
      Description copied from class: Decision
      Get the explanation for this decision.
      Specified by:
      getExplanation in class Decision
    • getDecisions

      public java.util.List<Decision> getDecisions()
      Description copied from class: Decision
      Return the list of all decisions that make up this decision
      Specified by:
      getDecisions in class Decision
    • equals

      public boolean equals​(java.lang.Object object)
      Overrides:
      equals in class java.lang.Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class java.lang.Object
    • toString

      public java.lang.String toString()
      Overrides:
      toString in class java.lang.Object
    • toXContent

      public org.elasticsearch.common.xcontent.XContentBuilder toXContent​(org.elasticsearch.common.xcontent.XContentBuilder builder, org.elasticsearch.common.xcontent.ToXContent.Params params) throws java.io.IOException
      Specified by:
      toXContent in interface org.elasticsearch.common.xcontent.ToXContent
      Throws:
      java.io.IOException
    • writeTo

      public void writeTo​(StreamOutput out) throws java.io.IOException
      Description copied from interface: Writeable
      Write this into the StreamOutput.
      Specified by:
      writeTo in interface Writeable
      Throws:
      java.io.IOException