Code example for AbstractHttpClient

Methods: execute

0
    @Override 
    public boolean autenticateCredentials() throws IOException { 
        HttpGet authenticationTest = new HttpGet(QueryBuilder.authenticationCheck());
        authenticationTest.setHeader("Accept", "application/xml");
        try { 
            httpClient.execute(authenticationTest, new BasicResponseHandler());
        } catch (HttpResponseException e) {
            return false; 
        } 
        return true; 
    } 
 
    @Override 
    public UserData lookupUserData(Entity entityType, String mbid) throws IOException {
        HttpEntity entity = get(QueryBuilder.userData(entityType, mbid));
        UserData userData = responseParser.parseUserData(entity.getContent());
        entity.consumeContent();
        return userData;
    } 
 
    @Override