public class JerseyWebTarget extends Object implements WebTarget, Initializable<JerseyWebTarget>
JAX-RS client target
contract.Modifier | Constructor and Description |
---|---|
protected |
JerseyWebTarget(UriBuilder uriBuilder,
ClientConfig clientConfig)
Create new web target instance.
|
protected |
JerseyWebTarget(UriBuilder uriBuilder,
JerseyWebTarget that)
Create new web target instance.
|
protected JerseyWebTarget(UriBuilder uriBuilder, JerseyWebTarget that)
uriBuilder
- builder for the target URI.that
- original target to copy the internal data from.protected JerseyWebTarget(UriBuilder uriBuilder, ClientConfig clientConfig)
uriBuilder
- builder for the target URI.clientConfig
- target configuration.public UriBuilder getUriBuilder()
getUriBuilder
in interface WebTarget
public JerseyWebTarget path(String path) throws NullPointerException
path
in interface WebTarget
NullPointerException
public JerseyWebTarget matrixParam(String name, Object... values) throws NullPointerException
matrixParam
in interface WebTarget
NullPointerException
public JerseyWebTarget queryParam(String name, Object... values) throws NullPointerException
queryParam
in interface WebTarget
NullPointerException
public JerseyInvocation.Builder request()
public JerseyInvocation.Builder request(String... acceptedResponseTypes)
public JerseyInvocation.Builder request(MediaType... acceptedResponseTypes)
public JerseyWebTarget resolveTemplate(String name, Object value) throws NullPointerException
resolveTemplate
in interface WebTarget
NullPointerException
public JerseyWebTarget resolveTemplate(String name, Object value, boolean encodeSlashInPath) throws NullPointerException
resolveTemplate
in interface WebTarget
NullPointerException
public JerseyWebTarget resolveTemplateFromEncoded(String name, Object value) throws NullPointerException
resolveTemplateFromEncoded
in interface WebTarget
NullPointerException
public JerseyWebTarget resolveTemplates(Map<String,Object> templateValues) throws NullPointerException
resolveTemplates
in interface WebTarget
NullPointerException
public JerseyWebTarget resolveTemplates(Map<String,Object> templateValues, boolean encodeSlashInPath) throws NullPointerException
resolveTemplates
in interface WebTarget
NullPointerException
public JerseyWebTarget resolveTemplatesFromEncoded(Map<String,Object> templateValues) throws NullPointerException
resolveTemplatesFromEncoded
in interface WebTarget
NullPointerException
public JerseyWebTarget register(Class<?> providerClass)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Object provider)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Class<?> providerClass, int bindingPriority)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Class<?> providerClass, Class<?>... contracts)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Class<?> providerClass, Map<Class<?>,Integer> contracts)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Object provider, int bindingPriority)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Object provider, Class<?>... contracts)
register
in interface Configurable<WebTarget>
public JerseyWebTarget register(Object provider, Map<Class<?>,Integer> contracts)
register
in interface Configurable<WebTarget>
public JerseyWebTarget property(String name, Object value)
property
in interface Configurable<WebTarget>
public ClientConfig getConfiguration()
Initializable
getConfiguration
in interface Configurable<WebTarget>
getConfiguration
in interface Initializable<JerseyWebTarget>
public JerseyWebTarget preInitialize()
Initializable
configuration
of this component
in order to improve performance during the first request.
Once this method is called no other method implementing Configurable
should be called
on this pre initialized component, otherwise the initialized client runtime will be discarded and the configuration
will change back to uninitialized.
preInitialize
in interface Initializable<JerseyWebTarget>
Copyright © 2007-2023, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.