2010-09-13 79 views
0

某些客戶端訂閱一個節點,我想知道如何獲得訂閱者。在Openfire中,如何獲取已訂閱節點的用戶?

在Openfire中是否有一些插件可以做到這一點?

+0

你能解釋一點,更確切地說你想要什麼?你提到了一個插件,所以假設你正在服務器上查找這些信息。你正在尋找待定訂閱者嗎? – Robin 2010-09-15 14:00:38

回答

0

您將需要從repo構建出smack版本以獲得PubSub支持。有關詳細信息,請參閱我的blog。一旦你有構建smack,這是你如何檢索訂戶列表

//Assume pubsub jid is pubsub.myserver 
PubSubManager mgr = new PubSubManager(conn, "pubsub.myserver"); 

//Assume we are dealing with leafnode 
LeafNode node = (LeafNode)mgr.getNode("mynode"); 

List<Subscriptions> subscriptions = node.getSubscriptions(); 
+0

夜間生成現已在http://www.igniterealtime.org/downloads/nightly_smack.jsp上提供 – Robin 2010-09-15 14:00:57

相關問題