protected WebClient(URI baseURI) { this(new LocalClientState(baseURI)); }
public void setBaseURI(URI baseURI) { this.baseURI = baseURI; resetCurrentUri(); }
public ClientState newState(URI currentURI, MultivaluedMap<String, String> headers, MultivaluedMap<String, String> templatesMap) { ClientState state = null; if (isSupportedScheme(currentURI)) { state = new LocalClientState(currentURI); } else { state = new LocalClientState(baseURI, currentURI); } if (headers != null) { state.setRequestHeaders(headers); } // we need to carry the template parameters forward MultivaluedMap<String, String> newTemplateParams = templates; if (newTemplateParams != null && templatesMap != null) { newTemplateParams.putAll(templatesMap); } else { newTemplateParams = templatesMap; } state.setTemplates(newTemplateParams); return state; }
public ClientState newState(URI currentURI, MultivaluedMap<String, String> headers, MultivaluedMap<String, String> templatesMap) { ClientState state = null; if (isHttpScheme(currentURI)) { state = new LocalClientState(currentURI); } else { state = new LocalClientState(baseURI, currentURI); } if (headers != null) { state.setRequestHeaders(headers); } // we need to carry the template parameters forward MultivaluedMap<String, String> newTemplateParams = templates; if (newTemplateParams != null && templatesMap != null) { newTemplateParams.putAll(templatesMap); } else { newTemplateParams = templatesMap; } state.setTemplates(newTemplateParams); return state; }
private void resetCurrentUri() { if (isSupportedScheme(baseURI)) { this.currentBuilder = new UriBuilderImpl().uri(baseURI); } else { this.currentBuilder = new UriBuilderImpl().uri("/"); } }
public LocalClientState(URI baseURI) { this.baseURI = baseURI; if (isHttpScheme(baseURI)) { this.currentBuilder = new UriBuilderImpl().uri(baseURI); } else { this.currentBuilder = new UriBuilderImpl().uri("/"); } }
public ClientState newState(URI currentURI, MultivaluedMap<String, String> headers, MultivaluedMap<String, String> templatesMap) { ClientState state = null; if (isSupportedScheme(currentURI)) { state = new LocalClientState(currentURI); } else { state = new LocalClientState(baseURI, currentURI); } if (headers != null) { state.setRequestHeaders(headers); } // we need to carry the template parameters forward MultivaluedMap<String, String> newTemplateParams = templates; if (newTemplateParams != null && templatesMap != null) { newTemplateParams.putAll(templatesMap); } else { newTemplateParams = templatesMap; } state.setTemplates(newTemplateParams); return state; }
private void resetCurrentUri() { if (isSupportedScheme(baseURI)) { this.currentBuilder = new UriBuilderImpl().uri(baseURI); } else { this.currentBuilder = new UriBuilderImpl().uri("/"); } }
protected WebClient(URI baseURI) { this(new LocalClientState(baseURI)); }
public LocalClientState(URI baseURI) { this.baseURI = baseURI; resetCurrentUri(); }
protected WebClient(URI baseURI) { this(new LocalClientState(baseURI)); }
public void setBaseURI(URI baseURI) { this.baseURI = baseURI; resetCurrentUri(); }
public ThreadLocalClientState(String baseURI) { this.initialState = new LocalClientState(URI.create(baseURI)); }
public LocalClientState(URI baseURI) { this.baseURI = baseURI; resetCurrentUri(); }
public ThreadLocalClientState(String baseURI, long timeToKeepState) { this.initialState = new LocalClientState(URI.create(baseURI)); this.timeToKeepState = timeToKeepState; }
public ThreadLocalClientState(String baseURI) { this.initialState = new LocalClientState(URI.create(baseURI)); }
public ThreadLocalClientState(String baseURI, long timeToKeepState) { this.initialState = new LocalClientState(URI.create(baseURI)); this.timeToKeepState = timeToKeepState; }
public ThreadLocalClientState(String baseURI, long timeToKeepState) { this.initialState = new LocalClientState(URI.create(baseURI)); this.timeToKeepState = timeToKeepState; }
public ThreadLocalClientState(String baseURI) { this.initialState = new LocalClientState(URI.create(baseURI)); }
public ClientProxyImpl(ClientState initialState, ClassLoader loader, ClassResourceInfo cri, boolean isRoot, boolean inheritHeaders, Object... varValues) { super(initialState); this.proxyLoader = loader; this.cri = cri; this.isRoot = isRoot; this.inheritHeaders = inheritHeaders; initValuesMap(varValues); }