mirror of
https://codeberg.org/Mercury-IM/Smack
synced 2025-12-18 11:01:08 +01:00
Remove deprecated method sin SDM and AdHocCommandManager
These methods are related to functionality which is no longer existend in XEP-0030.
This commit is contained in:
parent
84ef4047a7
commit
8841c4aed2
2 changed files with 0 additions and 109 deletions
|
|
@ -264,33 +264,6 @@ public final class AdHocCommandManager extends Manager {
|
|||
return serviceDiscoveryManager.discoverItems(jid, NAMESPACE);
|
||||
}
|
||||
|
||||
/**
|
||||
* Publish the commands to an specific JID.
|
||||
*
|
||||
* @param jid the full JID to publish the commands to.
|
||||
* @throws XMPPException if the operation failed for some reason.
|
||||
* @throws SmackException if there was no response from the server.
|
||||
* @throws InterruptedException
|
||||
* @deprecated This method uses no longer existent XEP-0030 features and will be removed.
|
||||
*/
|
||||
@SuppressWarnings("deprecation")
|
||||
@Deprecated
|
||||
// TODO: Remove in Smack 4.4.
|
||||
public void publishCommands(Jid jid) throws XMPPException, SmackException, InterruptedException {
|
||||
// Collects the commands to publish as items
|
||||
DiscoverItems discoverItems = new DiscoverItems();
|
||||
Collection<AdHocCommandInfo> xCommandsList = getRegisteredCommands();
|
||||
|
||||
for (AdHocCommandInfo info : xCommandsList) {
|
||||
DiscoverItems.Item item = new DiscoverItems.Item(info.getOwnerJID());
|
||||
item.setName(info.getName());
|
||||
item.setNode(info.getNode());
|
||||
discoverItems.addItem(item);
|
||||
}
|
||||
|
||||
serviceDiscoveryManager.publishItems(jid, NAMESPACE, discoverItems);
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns a command that represents an instance of a command in a remote
|
||||
* host. It is used to execute remote commands. The concept is similar to
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue