Enum SubscribePacket.RetainHandlingType
java.lang.Object
java.lang.Enum<SubscribePacket.RetainHandlingType>
software.amazon.awssdk.crt.mqtt5.packets.SubscribePacket.RetainHandlingType
- All Implemented Interfaces:
Serializable,Comparable<SubscribePacket.RetainHandlingType>
- Enclosing class:
- SubscribePacket
public static enum SubscribePacket.RetainHandlingType
extends Enum<SubscribePacket.RetainHandlingType>
Configures how retained messages should be handled when subscribing with a subscription that matches topics with
associated retained messages.
Enum values match MQTT5 spec encoding values.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionSubscriptions must not trigger any retained message publishes from the server.The server should always send all retained messages on topics that match a subscription's filter.The server should send retained messages on topics that match the subscription's filter, but only for the first matching subscription, per session. -
Method Summary
Modifier and TypeMethodDescriptiongetEnumValueFromInteger(int value) Creates a Java RetainHandlingType enum value from a native integer value.intgetValue()Returns the enum constant of this type with the specified name.static SubscribePacket.RetainHandlingType[]values()Returns an array containing the constants of this enum type, in the order they are declared.
-
Enum Constant Details
-
SEND_ON_SUBSCRIBE
The server should always send all retained messages on topics that match a subscription's filter. -
SEND_ON_SUBSCRIBE_IF_NEW
The server should send retained messages on topics that match the subscription's filter, but only for the first matching subscription, per session. -
DONT_SEND
Subscriptions must not trigger any retained message publishes from the server.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (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 type has no constant with the specified nameNullPointerException- if the argument is null
-
getValue
public int getValue()- Returns:
- The native enum integer value associated with this Java enum value
-
getEnumValueFromInteger
Creates a Java RetainHandlingType enum value from a native integer value.- Parameters:
value- native integer value for RetainHandlingType- Returns:
- a new RetainHandlingType value
-