public class MqttClientConnectionConfig extends java.lang.Object implements Mqtt5ClientConnectionConfig, Mqtt5ClientConnectionConfig.RestrictionsForServer, Mqtt5ClientConnectionConfig.RestrictionsForClient, Mqtt3ClientConnectionConfig, Mqtt3ClientConnectionConfig.RestrictionsForClient
Mqtt5ClientConnectionConfig.RestrictionsForClient, Mqtt5ClientConnectionConfig.RestrictionsForServer
Mqtt3ClientConnectionConfig.RestrictionsForClient
Constructor and Description |
---|
MqttClientConnectionConfig(int keepAlive,
long sessionExpiryInterval,
boolean hasWillPublish,
@Nullable Mqtt5EnhancedAuthMechanism enhancedAuthMechanism,
int receiveMaximum,
int maximumPacketSize,
int topicAliasMaximum,
boolean problemInformationRequested,
boolean responseInformationRequested,
int sendMaximum,
int sendMaximumPacketSize,
int sendTopicAliasMaximum,
@NotNull MqttQos maximumQos,
boolean retainAvailable,
boolean wildcardSubscriptionAvailable,
boolean sharedSubscriptionAvailable,
boolean subscriptionIdentifiersAvailable,
@NotNull io.netty.channel.Channel channel) |
Modifier and Type | Method and Description |
---|---|
boolean |
areSubscriptionIdentifiersAvailable()
Returns whether the server accepts subscription identifiers from the client.
|
@NotNull io.netty.channel.Channel |
getChannel() |
@NotNull java.util.Optional<Mqtt5EnhancedAuthMechanism> |
getEnhancedAuthMechanism() |
int |
getKeepAlive() |
int |
getMaximumPacketSize()
Returns the maximum packet size the client accepts from the server.
|
@NotNull MqttQos |
getMaximumQos()
Returns the maximum
QoS the server accepts from the client. |
@Nullable Mqtt5EnhancedAuthMechanism |
getRawEnhancedAuthMechanism() |
int |
getReceiveMaximum()
Returns the maximum amount of not acknowledged publishes with QoS 1 or 2 the client accepts from the server
concurrently.
|
@NotNull MqttClientConnectionConfig |
getRestrictionsForClient() |
@NotNull MqttClientConnectionConfig |
getRestrictionsForServer() |
int |
getSendMaximum()
Returns the maximum amount of not acknowledged publishes with QoS 1 or 2 the client sends to the server
concurrently.
|
int |
getSendMaximumPacketSize()
Returns the maximum packet size the client sends to the server.
|
@Nullable MqttTopicAliasMapping |
getSendTopicAliasMapping() |
int |
getSendTopicAliasMaximum()
Returns the maximum amount of topic aliases the client sends to the server.
|
long |
getSessionExpiryInterval() |
int |
getTopicAliasMaximum()
Returns the maximum amount of topic aliases the client accepts from the server.
|
boolean |
hasWillPublish() |
boolean |
isProblemInformationRequested()
Returns whether the client requested problem information from the server.
|
boolean |
isResponseInformationRequested()
Returns whether the client requested response information from the server.
|
boolean |
isRetainAvailable()
Returns whether the server accepts retained messages from the client.
|
boolean |
isSharedSubscriptionAvailable()
Returns whether the server accepts shared subscriptions from the client.
|
boolean |
isWildcardSubscriptionAvailable()
Returns whether the server accepts wildcard subscriptions from the client.
|
public MqttClientConnectionConfig(int keepAlive, long sessionExpiryInterval, boolean hasWillPublish, @Nullable @Nullable Mqtt5EnhancedAuthMechanism enhancedAuthMechanism, int receiveMaximum, int maximumPacketSize, int topicAliasMaximum, boolean problemInformationRequested, boolean responseInformationRequested, int sendMaximum, int sendMaximumPacketSize, int sendTopicAliasMaximum, @NotNull @NotNull MqttQos maximumQos, boolean retainAvailable, boolean wildcardSubscriptionAvailable, boolean sharedSubscriptionAvailable, boolean subscriptionIdentifiersAvailable, @NotNull @NotNull io.netty.channel.Channel channel)
public int getKeepAlive()
getKeepAlive
in interface MqttClientConnectionConfig
public long getSessionExpiryInterval()
getSessionExpiryInterval
in interface Mqtt5ClientConnectionConfig
public boolean hasWillPublish()
hasWillPublish
in interface MqttClientConnectionConfig
@NotNull public @NotNull java.util.Optional<Mqtt5EnhancedAuthMechanism> getEnhancedAuthMechanism()
getEnhancedAuthMechanism
in interface Mqtt5ClientConnectionConfig
@Nullable public @Nullable Mqtt5EnhancedAuthMechanism getRawEnhancedAuthMechanism()
@NotNull public @NotNull MqttClientConnectionConfig getRestrictionsForServer()
getRestrictionsForServer
in interface Mqtt5ClientConnectionConfig
@NotNull public @NotNull MqttClientConnectionConfig getRestrictionsForClient()
getRestrictionsForClient
in interface Mqtt3ClientConnectionConfig
getRestrictionsForClient
in interface Mqtt5ClientConnectionConfig
public int getReceiveMaximum()
Mqtt5ClientConnectionConfig.RestrictionsForServer
The value is determined by Mqtt5ConnectRestrictions#getReceiveMaximum()
.
getReceiveMaximum
in interface Mqtt5ClientConnectionConfig.RestrictionsForServer
public int getMaximumPacketSize()
Mqtt5ClientConnectionConfig.RestrictionsForServer
The value is determined by Mqtt5ConnectRestrictions#getMaximumPacketSize()
.
getMaximumPacketSize
in interface Mqtt5ClientConnectionConfig.RestrictionsForServer
public int getTopicAliasMaximum()
Mqtt5ClientConnectionConfig.RestrictionsForServer
The value is determined by Mqtt5ConnectRestrictions#getTopicAliasMaximum()
.
getTopicAliasMaximum
in interface Mqtt5ClientConnectionConfig.RestrictionsForServer
public boolean isProblemInformationRequested()
Mqtt5ClientConnectionConfig.RestrictionsForServer
The value is determined by Mqtt5ConnectRestrictions#isRequestProblemInformation()
.
isProblemInformationRequested
in interface Mqtt5ClientConnectionConfig.RestrictionsForServer
public boolean isResponseInformationRequested()
Mqtt5ClientConnectionConfig.RestrictionsForServer
The value is determined by Mqtt5ConnectRestrictions#isRequestResponseInformation()
.
isResponseInformationRequested
in interface Mqtt5ClientConnectionConfig.RestrictionsForServer
public int getSendMaximum()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by the minimum of Mqtt5ConnectRestrictions#getSendMaximum()
and MqttConnAckRestrictions#getReceiveMaximum()
.
getSendMaximum
in interface Mqtt3ClientConnectionConfig.RestrictionsForClient
getSendMaximum
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public int getSendMaximumPacketSize()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by the minimum of Mqtt5ConnectRestrictions#getSendMaximumPacketSize()
and MqttConnAckRestrictions#getMaximumPacketSize()
.
getSendMaximumPacketSize
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public int getSendTopicAliasMaximum()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by the minimum of Mqtt5ConnectRestrictions#getSendTopicAliasMaximum()
and MqttConnAckRestrictions#getTopicAliasMaximum()
.
getSendTopicAliasMaximum
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
@Nullable public @Nullable MqttTopicAliasMapping getSendTopicAliasMapping()
@NotNull public @NotNull MqttQos getMaximumQos()
Mqtt5ClientConnectionConfig.RestrictionsForClient
QoS
the server accepts from the client.
The value is determined by MqttConnAckRestrictions#getMaximumQos()
.
getMaximumQos
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public boolean isRetainAvailable()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by MqttConnAckRestrictions#isRetainAvailable()
.
isRetainAvailable
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public boolean isWildcardSubscriptionAvailable()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by MqttConnAckRestrictions#isWildcardSubscriptionAvailable()
.
isWildcardSubscriptionAvailable
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public boolean isSharedSubscriptionAvailable()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by MqttConnAckRestrictions#isSharedSubscriptionAvailable()
.
isSharedSubscriptionAvailable
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
public boolean areSubscriptionIdentifiersAvailable()
Mqtt5ClientConnectionConfig.RestrictionsForClient
The value is determined by MqttConnAckRestrictions#areSubscriptionIdentifiersAvailable()
.
areSubscriptionIdentifiersAvailable
in interface Mqtt5ClientConnectionConfig.RestrictionsForClient
@NotNull public @NotNull io.netty.channel.Channel getChannel()