public DiscoverInfo discoverInfo(Jid entityID) throws NoResponseException, XMPPErrorException, NotConnectedException, InterruptedException {
        if (entityID == null)
            return discoverInfo(null, null);

        synchronized (discoInfoLookupShortcutMechanisms) {
            for (DiscoInfoLookupShortcutMechanism discoInfoLookupShortcutMechanism : discoInfoLookupShortcutMechanisms) {
                DiscoverInfo info = discoInfoLookupShortcutMechanism.getDiscoverInfoByUser(this, entityID);
                if (info != null) {
                    // We were able to retrieve the information from Entity Caps and
                    // avoided a disco request, hurray!
                    return info;
                }
            }
        }

        // Last resort: Standard discovery.
        return discoverInfo(entityID, null);
    }
public DiscoverInfo discoverInfo ( Jid entityID ) throws NoResponseException , XMPPErrorException , NotConnectedException , InterruptedException { if ( entityID == null ) return discoverInfo ( null , null ) ; synchronized ( discoInfoLookupShortcutMechanisms ) { for ( DiscoInfoLookupShortcutMechanism discoInfoLookupShortcutMechanism : discoInfoLookupShortcutMechanisms ) { DiscoverInfo info = discoInfoLookupShortcutMechanism . getDiscoverInfoByUser ( this , entityID ) ; if ( info != null ) { return info ; } } } return discoverInfo ( entityID , null ) ; }
Returns the discovered information of a given XMPP entity addressed by its JID.
Use null as entityID to query the server

@param entityID the address of the XMPP entity or null.
@return the discovered information.
@throws XMPPErrorException
@throws NoResponseException
@throws NotConnectedException
@throws InterruptedException