MQTT Java客户端如何设置订阅标识符和别名?

MQTT Java客户端的MqttSubscription找不到这两个属性:

public class MqttSubscription {

	private boolean mutable = true;
	private String topic;
	private int qos = 1;
	private boolean noLocal = false;
	private boolean retainAsPublished = false;
	private int retainHandling = 0;
	private int messageId;
}
		properties.setSubscriptionIdentifiers(subscriptionIdentifiers);
		properties.setTopicAlias(topicAlias);

https://github.com/eclipse/paho.mqtt.java/blob/f4e0db802a4433645ef011e711646a09ec9fae89/org.eclipse.paho.mqttv5.client.test/src/test/java/org/eclipse/paho/mqttv5/common/packet/MqttPublishTest.java#L114-L115

谢谢~~
MqttClient的subscribe()方法的确没办法设置 MqttProperties,但MqttAsyncClient可以设置。我目前是通过继承MqttClient,扩展subscribe方法,直接调用MqttAsyncClient来实现。

public class ExtMqttClient extends MqttClient
{
    public IMqttToken subscribe(MqttSubscription subscription, Integer subscriptionIdentifier) throws MqttException
    {
        return subscribe(new MqttSubscription[] {subscription}, subscriptionIdentifier);
    }
    
    public IMqttToken subscribe(MqttSubscription[] subscriptions, Integer subscriptionIdentifier) throws MqttException
    {
        MqttProperties mqttProperties = new MqttProperties();
        mqttProperties.setSubscriptionIdentifier(subscriptionIdentifier);
        
        return subscribe(subscriptions, mqttProperties);
    }
    
    public IMqttToken subscribe(MqttSubscription subscription, MqttProperties mqttProperties) throws MqttException
    {
        IMqttToken tok = aClient.subscribe(subscription, null, null, (IMqttMessageListener)null, mqttProperties);
        tok.waitForCompletion(getTimeToWait());
        
        return tok;
    }
    
    public IMqttToken subscribe(MqttSubscription[] subscriptions, MqttProperties mqttProperties) throws MqttException
    {
        IMqttToken tok = aClient.subscribe(subscriptions, null, null, (IMqttMessageListener[])null, mqttProperties);
        tok.waitForCompletion(getTimeToWait());
        
        return tok;
    }
}

还有一个疑问:MqttProperties 的 setTopicAlias(Integer) 是Integer类型的,而上述客户端可以设置成字符串的。这是为何?