Package com.hivemq.client.mqtt
Enum Class MqttGlobalPublishFilter
- All Implemented Interfaces:
Serializable,Comparable<MqttGlobalPublishFilter>,Constable
Global filter for incoming Publish messages.
Global means not filtering for individual subscriptions of a Subscribe message.
- Since:
- 1.0
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionFilter matching all incoming Publish messages.Filter matching the incoming Publish messages that are not consumed in per subscription or other global flows.Filter matching the incoming Publish messages resulting from subscriptions made by the client.Filter matching the incoming Publish messages not resulting from any subscription made by the client. -
Method Summary
Modifier and TypeMethodDescriptionstatic MqttGlobalPublishFilterReturns the enum constant of this class with the specified name.static MqttGlobalPublishFilter[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
ALL
Filter matching all incoming Publish messages.ALL =
SUBSCRIBED+UNSOLICITED. -
SUBSCRIBED
Filter matching the incoming Publish messages resulting from subscriptions made by the client.SUBSCRIBED +
UNSOLICITED=ALL. -
UNSOLICITED
Filter matching the incoming Publish messages not resulting from any subscription made by the client.UNSOLICITED +
SUBSCRIBED=ALL. -
REMAINING
Filter matching the incoming Publish messages that are not consumed in per subscription or other global flows.This filter will not match any messages if
- the
ALLfilter is used or - both
SUBSCRIBEDandUNSOLICITEDfilters are used.
Example (pseudo-code):
stream1 = client.subscribePublishes("a/#")client.subscribe("b/#")stream2 = client.publishes(SUBSCRIBED)stream3 = client.publishes(REMAINING)
"a/b"will be emitted instream1andstream2."b/c"will be emitted instream2"c/d"will be emitted instream3as there is no other stream registered for the topic.
- the
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-