public final class MqttUtil extends Object
| 限定符和类型 | 方法和说明 |
|---|---|
static boolean |
cleanSession(io.netty.channel.Channel channel) |
static void |
cleanSession(io.netty.channel.Channel channel,
boolean cleanSession) |
static String |
clientID(io.netty.channel.Channel channel) |
static void |
clientID(io.netty.channel.Channel channel,
String clientID) |
static <T,K> T |
defaultGet(Map<K,T> map,
K key,
T defaultValue) |
static Object |
getAttribute(io.netty.channel.ChannelHandlerContext ctx,
io.netty.util.AttributeKey<Object> key) |
static void |
keepAlive(io.netty.channel.Channel channel,
int keepAlive) |
static int |
messageId(io.netty.handler.codec.mqtt.MqttMessage msg) |
static String |
payload2Str(io.netty.buffer.ByteBuf content) |
static byte[] |
readBytesAndRewind(io.netty.buffer.ByteBuf payload) |
static String |
userName(io.netty.channel.Channel channel) |
static void |
userName(io.netty.channel.Channel channel,
String username) |
public static Object getAttribute(io.netty.channel.ChannelHandlerContext ctx, io.netty.util.AttributeKey<Object> key)
public static void keepAlive(io.netty.channel.Channel channel,
int keepAlive)
public static void cleanSession(io.netty.channel.Channel channel,
boolean cleanSession)
public static boolean cleanSession(io.netty.channel.Channel channel)
public static void clientID(io.netty.channel.Channel channel,
String clientID)
public static String clientID(io.netty.channel.Channel channel)
public static void userName(io.netty.channel.Channel channel,
String username)
public static String userName(io.netty.channel.Channel channel)
public static <T,K> T defaultGet(Map<K,T> map, K key, T defaultValue)
public static int messageId(io.netty.handler.codec.mqtt.MqttMessage msg)
public static byte[] readBytesAndRewind(io.netty.buffer.ByteBuf payload)
public static String payload2Str(io.netty.buffer.ByteBuf content)
Copyright © 2021. All rights reserved.