Class QueueCheck

java.lang.Object
org.acemq.amqp.transport.QueueCheck

public final class QueueCheck extends Object
What a broker says about a queue somebody is about to declare.

Four answers rather than two, because "the queue is not the way you want it" and "I cannot tell you" are different facts and collapsing them would make the second look like the first. A transport that cannot inspect a queue says unsupported(), and callers report that as unknown rather than as agreement.

  • Method Details

    • matches

      public static QueueCheck matches()
      Returns:
      the queue exists and matches
    • absent

      public static QueueCheck absent()
      Returns:
      there is no such queue
    • differs

      public static QueueCheck differs(String detail)
      Parameters:
      detail - what differs, in the broker's own words where there are any. This ends up in front of whoever is deciding what to do about it, so it should name the argument rather than say that something is wrong
      Returns:
      the queue exists with settings that would be refused
    • unsupported

      public static QueueCheck unsupported()
      Returns:
      this transport cannot answer the question
    • result

      public QueueCheck.Result result()
      Returns:
      which answer this is
    • detail

      public @Nullable String detail()
      Returns:
      what differs, when something does
    • toString

      public String toString()
      Overrides:
      toString in class Object