Examples of discoverInfo()


Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

            boolean discovered = sdm.discoverInfo(jid.getRAW()).getIdentities()
                .hasNext();

            if (!discovered && jid.isBareJID()) // FIXME: removed the hard coded
                                                // suffix
                discovered = sdm.discoverInfo(jid.getRAW() + "/Saros")
                    .getIdentities().hasNext();

            /*
             * discovery does not change any state, if the user wanted to cancel
             * it, we can do that even after the execution finished
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

        ServiceDiscoveryManager sdm = ServiceDiscoveryManager
            .getInstanceFor(sarosNet.getConnection());

        try {
            return sdm.discoverInfo(recipient.toString());
        } catch (XMPPException e) {

            log.warn(
                "Service Discovery failed on recipient " + recipient.toString()
                    + " server:" + sarosNet.getConnection().getHost() + ":", e);
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

    public boolean isEmailAvailable() {
        ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(connection);

        try {
            String workgroupService = StringUtils.parseServer(workgroupJID);
            DiscoverInfo infoResult = discoManager.discoverInfo(workgroupService);
            return infoResult.containsFeature("jive:email:provider");
        }
        catch (XMPPException e) {
            return false;
        }
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

        while (iter.hasNext()) {
            DiscoverItems.Item item = iter.next();
            try {
                DiscoverInfo info;
                try {
                    info = discoManager.discoverInfo(item.getEntityID());
                }
                catch (XMPPException e) {
                    // Ignore Case
                    continue;
                }
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

        ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(connection);
        DiscoverItems items = discoManager.discoverItems(connection.getServiceName());
        for (Iterator<DiscoverItems.Item> it = items.getItems(); it.hasNext();) {
            DiscoverItems.Item item = it.next();
            try {
                DiscoverInfo info = discoManager.discoverInfo(item.getEntityID());
                if (info.containsFeature("http://jabber.org/protocol/muc")) {
                    answer.add(item.getEntityID());
                }
            }
            catch (XMPPException e) {
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

        ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(connection);
        DiscoverItems items = discoManager.discoverItems(connection.getServiceName());
        for (Iterator<DiscoverItems.Item> it = items.getItems(); it.hasNext();) {
            DiscoverItems.Item item = it.next();
            try {
                DiscoverInfo info = discoManager.discoverInfo(item.getEntityID());
                if (info.containsFeature("http://jabber.org/protocol/muc")) {
                    answer.add(item.getEntityID());
                }
            }
            catch (XMPPException e) {
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

        ServiceDiscoveryManager discoManager = ServiceDiscoveryManager.getInstanceFor(con);
        DiscoverItems items = discoManager.discoverItems(con.getServiceName());
        for (Iterator it = items.getItems(); it.hasNext();) {
            DiscoverItems.Item item = (DiscoverItems.Item) it.next();
            try {
                DiscoverInfo info = discoManager.discoverInfo(item.getEntityID());
                if (info.containsFeature("jabber:iq:search")) {
                    searchServices.add(item.getEntityID());
                }
            }
            catch (XMPPException e) {
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

//                if (item.getEntityID().startsWith("rtpbridge.")) {
//                    return true;
//                }
//            }
           
            DiscoverInfo discoInfo = disco.discoverInfo(connection.getServiceName());
            Iterator<DiscoverInfo.Identity> iter = discoInfo.getIdentities();
            while (iter.hasNext()) {
                DiscoverInfo.Identity identity = iter.next();
                if ((identity.getName() != null) && (identity.getName().startsWith("rtpbridge"))) {
          return true;
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

            DiscoverItems items = disco.discoverItems(connection.getServiceName());

            Iterator<DiscoverItems.Item> iter = items.getItems();
            while (iter.hasNext()) {
                DiscoverItems.Item item = iter.next();
                DiscoverInfo info = disco.discoverInfo(item.getEntityID());

                Iterator<DiscoverInfo.Identity> iter2 = info.getIdentities();
                while (iter2.hasNext()) {
                    DiscoverInfo.Identity identity = iter2.next();
                    if (identity.getCategory().equals("proxy") && identity.getType().equals("stun"))
View Full Code Here

Examples of org.jivesoftware.smackx.ServiceDiscoveryManager.discoverInfo()

     *         otherwise <code>false</code>
     * @throws XMPPException if there was an error querying target for supported features
     */
    private boolean supportsSocks5(String targetJID) throws XMPPException {
        ServiceDiscoveryManager serviceDiscoveryManager = ServiceDiscoveryManager.getInstanceFor(this.connection);
        DiscoverInfo discoverInfo = serviceDiscoveryManager.discoverInfo(targetJID);
        return discoverInfo.containsFeature(NAMESPACE);
    }

    /**
     * Returns a list of JIDs of SOCKS5 proxies by querying the XMPP server. The SOCKS5 proxies are
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.