public BoBData requestBoB ( Jid to , BoBHash bobHash ) throws NotLoggedInException , NoResponseException , XMPPErrorException , NotConnectedException , InterruptedException { BoBData bobData = BOB_CACHE . lookup ( bobHash ) ; if ( bobData != null ) { return bobData ; } BoBIQ requestBoBIQ = new BoBIQ ( bobHash ) ; requestBoBIQ . setType ( Type . get ) ; requestBoBIQ . setTo ( to ) ; XMPPConnection connection = getAuthenticatedConnectionOrThrow ( ) ; BoBIQ responseBoBIQ = connection . createStanzaCollectorAndSend ( requestBoBIQ ) . nextResultOrThrow ( ) ; bobData = responseBoBIQ . getBoBData ( ) ; BOB_CACHE . put ( bobHash , bobData ) ; return bobData ; }
Request BoB data .