Interface Mqtt5ConnectBuilderBase<B extends Mqtt5ConnectBuilderBase<B>>
- Type Parameters:
B- the type of the builder.
- All Known Subinterfaces:
Mqtt5ConnectBuilder,Mqtt5ConnectBuilder.Nested<P>,Mqtt5ConnectBuilder.Send<P>
Mqtt5Connect.- Since:
- 1.0
-
Method Summary
Modifier and TypeMethodDescriptioncleanStart(boolean cleanStart) Sets whether the clientstarts a clean session.enhancedAuth(@Nullable Mqtt5EnhancedAuthMechanism enhancedAuthMechanism) keepAlive(int keepAlive) Sets thekeep alivein seconds.Disables thekeep aliveby setting it toMqtt5Connect.NO_KEEP_ALIVE.Disables thesession expiryby setting it toMqtt5Connect.NO_SESSION_EXPIRY.@NotNull Mqtt5ConnectRestrictionsBuilder.Nested<? extends B> Fluent counterpart ofrestrictions(Mqtt5ConnectRestrictions).restrictions(@NotNull Mqtt5ConnectRestrictions restrictions) Sets therestrictionsfrom the client.sessionExpiryInterval(long sessionExpiryInterval) Sets thesession expiry intervalin seconds.@NotNull Mqtt5SimpleAuthBuilder.Nested<? extends B> Fluent counterpart ofsimpleAuth(Mqtt5SimpleAuth).simpleAuth(@Nullable Mqtt5SimpleAuth simpleAuth) Sets the optionalsimple authentication and/or authorization related data.@NotNull Mqtt5UserPropertiesBuilder.Nested<? extends B> Fluent counterpart ofuserProperties(Mqtt5UserProperties).userProperties(@NotNull Mqtt5UserProperties userProperties) Sets theUser Properties.@NotNull Mqtt5WillPublishBuilder.Nested<? extends B> Fluent counterpart ofwillPublish(Mqtt5Publish).willPublish(@Nullable Mqtt5Publish willPublish) Sets the optionalWill Publish.
-
Method Details
-
keepAlive
Sets thekeep alivein seconds.The value must be in the range of an unsigned short: [0, 65_535].
- Parameters:
keepAlive- the keep alive in seconds.- Returns:
- the builder.
-
noKeepAlive
Disables thekeep aliveby setting it toMqtt5Connect.NO_KEEP_ALIVE.- Returns:
- the builder.
-
cleanStart
Sets whether the clientstarts a clean session.- Parameters:
cleanStart- whether the client starts a clean session.- Returns:
- the builder.
-
sessionExpiryInterval
Sets thesession expiry intervalin seconds.The value must be in the range of an unsigned int: [0, 4_294_967_295]. 4_294_967_295 disables session expiry.
- Parameters:
sessionExpiryInterval- the session expiry interval in seconds.- Returns:
- the builder.
-
noSessionExpiry
Disables thesession expiryby setting it toMqtt5Connect.NO_SESSION_EXPIRY.- Returns:
- the builder.
-
restrictions
Sets therestrictionsfrom the client.- Parameters:
restrictions- the restrictions from the client.- Returns:
- the builder.
-
restrictions
Fluent counterpart ofrestrictions(Mqtt5ConnectRestrictions).Calling
Mqtt5ConnectRestrictionsBuilder.Nested.applyRestrictions()on the returned builder has the effect ofextendingthe current restrictions.- Returns:
- the fluent builder for the restrictions.
- See Also:
-
simpleAuth
Sets the optionalsimple authentication and/or authorization related data.- Parameters:
simpleAuth- the simple auth related data ornullto remove any previously set simple auth related data.- Returns:
- the builder.
-
simpleAuth
Fluent counterpart ofsimpleAuth(Mqtt5SimpleAuth).Calling
Mqtt5SimpleAuthBuilder.Nested.Complete.applySimpleAuth()on the returned builder has the same effect as callingsimpleAuth(Mqtt5SimpleAuth)with the result ofMqtt5SimpleAuthBuilder.Complete.build().- Returns:
- the fluent builder for the simple auth related data.
- See Also:
-
enhancedAuth
@CheckReturnValue @NotNull B enhancedAuth(@Nullable @Nullable Mqtt5EnhancedAuthMechanism enhancedAuthMechanism) - Parameters:
enhancedAuthMechanism- the enhanced auth mechanism ornullto remove any previously set enhanced auth mechanism.- Returns:
- the builder.
-
willPublish
Sets the optionalWill Publish.- Parameters:
willPublish- the Will Publish ornullto remove any previously set Will Publish.- Returns:
- the builder.
-
willPublish
Fluent counterpart ofwillPublish(Mqtt5Publish).Calling
Mqtt5WillPublishBuilder.Nested.Complete.applyWillPublish()on the returned builder has the same effect as callingwillPublish(Mqtt5Publish)with the result ofMqtt5WillPublishBuilder.Complete.build().- Returns:
- the fluent builder for the Will Publish.
- See Also:
-
userProperties
Sets theUser Properties.- Parameters:
userProperties- the User Properties.- Returns:
- the builder.
-
userProperties
Fluent counterpart ofuserProperties(Mqtt5UserProperties).Calling
Mqtt5UserPropertiesBuilder.Nested.applyUserProperties()on the returned builder has the effect ofextendingthe current User Properties.- Returns:
- the fluent builder for the User Properties.
- See Also:
-