public AbstractHtmlClientImpl()

in src/main/java/org/apache/sling/hapi/client/impl/AbstractHtmlClientImpl.java [67:78]


    public AbstractHtmlClientImpl(String baseUrl, String user, String password) throws URISyntaxException {
        this.baseUrl = new URI(baseUrl);
        HttpHost targetHost = URIUtils.extractHost(this.baseUrl);
        BasicCredentialsProvider credsProvider = new BasicCredentialsProvider();
        credsProvider.setCredentials(
                new AuthScope(targetHost.getHostName(), targetHost.getPort()),
                new UsernamePasswordCredentials(user, password));
        this.client = HttpClientBuilder.create()
                .setDefaultCredentialsProvider(credsProvider)
                .setRedirectStrategy(new LaxRedirectStrategy())
                .build();
    }