package io.netty.handler.codec.mqtt;

import g.a.a.a.a;
import io.netty.util.internal.StringUtil;
import kotlinx.serialization.json.internal.AbstractJsonLexerKt;

/* JADX INFO: loaded from: classes.dex */
public final class MqttPublishVariableHeader {
    private final int packetId;
    private final String topicName;

    public MqttPublishVariableHeader(String str, int i2) {
        this.topicName = str;
        this.packetId = i2;
    }

    @Deprecated
    public int messageId() {
        return this.packetId;
    }

    public int packetId() {
        return this.packetId;
    }

    public String toString() {
        StringBuilder sb = new StringBuilder(StringUtil.simpleClassName(this));
        sb.append(AbstractJsonLexerKt.BEGIN_LIST);
        sb.append("topicName=");
        sb.append(this.topicName);
        sb.append(", packetId=");
        return a.w(sb, this.packetId, AbstractJsonLexerKt.END_LIST);
    }

    public String topicName() {
        return this.topicName;
    }
}
