Package org.refcodes.rest
Interface RestClient
-
- All Superinterfaces:
org.refcodes.net.MediaTypeFactoryLookup
,org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
,org.refcodes.net.OauthTokenAccessor
,org.refcodes.net.OauthTokenAccessor.OauthTokenBuilder<RestClient>
,org.refcodes.net.OauthTokenAccessor.OauthTokenMutator
,org.refcodes.net.OauthTokenAccessor.OauthTokenProperty
,org.refcodes.runtime.RequestCorrelation<RestClient>
,RestDeleteClient
,RestGetClient
,RestPostClient
,RestPutClient
,RestRequestClient
,org.refcodes.runtime.SessionCorrelation<RestClient>
,org.refcodes.net.UserAgentAccessor
,org.refcodes.net.UserAgentAccessor.UserAgentBuilder<RestClient>
,org.refcodes.net.UserAgentAccessor.UserAgentMutator
,org.refcodes.net.UserAgentAccessor.UserAgentProperty
- All Known Subinterfaces:
HttpDiscoveryRestClient<B>
,HttpRestClient
,LoopbackRestClient
- All Known Implementing Classes:
AbstractHttpDiscoveryRestClientDecorator
,AbstractHttpRestClientDecorator
,AbstractRestClient
,HttpRestClientImpl
,HttpRestClientSingleton
,LoopbackRestClientImpl
,LoopbackRestClientSingleton
public interface RestClient extends org.refcodes.net.OauthTokenAccessor.OauthTokenProperty, org.refcodes.net.OauthTokenAccessor.OauthTokenBuilder<RestClient>, RestGetClient, RestPostClient, RestDeleteClient, RestPutClient, org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup, org.refcodes.net.UserAgentAccessor.UserAgentProperty, org.refcodes.net.UserAgentAccessor.UserAgentBuilder<RestClient>, org.refcodes.runtime.RequestCorrelation<RestClient>, org.refcodes.runtime.SessionCorrelation<RestClient>
A client to send requests for communicating with a RESTful server such as theHttpRestServer
. For marshaling and unmarshaling HTTP bodies you have to register the accordingMediaTypeFactory
instances being capable of handling the accordingMediaType
definitions. Examples for ready to useMediaTypeFactory
implementations areJsonMediaTypeFactory
,XmlMediaTypeFactory
FormMediaTypeFactory
TextMediaTypeFactory
RestClient
interface, such as theHttpRestClientImpl
, are initialized with some commonMediaTypeFactory
instances. You may set an individual User-Agent viaUserAgentAccessor.UserAgentMutator.setUserAgent(String)
, not setting it will result in the default User-Agent to be set as coded into theRestClient
implementations.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.refcodes.net.MediaTypeFactoryLookup
org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
-
Nested classes/interfaces inherited from interface org.refcodes.net.OauthTokenAccessor
org.refcodes.net.OauthTokenAccessor.OauthTokenBuilder<B extends org.refcodes.net.OauthTokenAccessor.OauthTokenBuilder<B>>, org.refcodes.net.OauthTokenAccessor.OauthTokenMutator, org.refcodes.net.OauthTokenAccessor.OauthTokenProperty
-
Nested classes/interfaces inherited from interface org.refcodes.net.UserAgentAccessor
org.refcodes.net.UserAgentAccessor.UserAgentBuilder<B extends org.refcodes.net.UserAgentAccessor.UserAgentBuilder<B>>, org.refcodes.net.UserAgentAccessor.UserAgentMutator, org.refcodes.net.UserAgentAccessor.UserAgentProperty
-
-
Method Summary
All Methods Instance Methods Default Methods Modifier and Type Method Description default RestClient
withDisableRequestCorrelation()
default RestClient
withDisableSessionCorrelation()
default RestClient
withEnableRequestCorrelation()
default RestClient
withEnableSessionCorrelation()
default RestClient
withRequestCorrelation(boolean hasRequestCorrelation)
default RestClient
withSessionCorrelation(boolean hasSessionCorrelation)
default RestClient
withUserAgent(java.lang.String aUserAgent)
-
Methods inherited from interface org.refcodes.net.MediaTypeFactoryLookup
getFactoryMediaTypes, hasMediaTypeFactory, toMediaTypeFactory
-
Methods inherited from interface org.refcodes.net.MediaTypeFactoryLookup.MutableMediaTypeFactoryLookup
addMediaTypeFactory
-
Methods inherited from interface org.refcodes.net.OauthTokenAccessor.OauthTokenBuilder
withOAuthToken
-
Methods inherited from interface org.refcodes.net.OauthTokenAccessor.OauthTokenMutator
setOauthToken
-
Methods inherited from interface org.refcodes.runtime.RequestCorrelation
disableRequestCorrelation, enableRequestCorrelation, hasRequestCorrelation, setRequestCorrelation
-
Methods inherited from interface org.refcodes.rest.RestDeleteClient
buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, buildDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete, doDelete
-
Methods inherited from interface org.refcodes.rest.RestGetClient
buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, buildGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet, doGet
-
Methods inherited from interface org.refcodes.rest.RestPostClient
buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, buildPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost, doPost
-
Methods inherited from interface org.refcodes.rest.RestPutClient
buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, buildPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut, doPut
-
Methods inherited from interface org.refcodes.rest.RestRequestClient
buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, buildRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest, doRequest
-
-
-
-
Method Detail
-
withUserAgent
default RestClient withUserAgent(java.lang.String aUserAgent)
- Specified by:
withUserAgent
in interfaceorg.refcodes.net.UserAgentAccessor.UserAgentBuilder<RestClient>
-
withSessionCorrelation
default RestClient withSessionCorrelation(boolean hasSessionCorrelation)
- Specified by:
withSessionCorrelation
in interfaceorg.refcodes.runtime.SessionCorrelation<RestClient>
-
withEnableSessionCorrelation
default RestClient withEnableSessionCorrelation()
- Specified by:
withEnableSessionCorrelation
in interfaceorg.refcodes.runtime.SessionCorrelation<RestClient>
-
withDisableSessionCorrelation
default RestClient withDisableSessionCorrelation()
- Specified by:
withDisableSessionCorrelation
in interfaceorg.refcodes.runtime.SessionCorrelation<RestClient>
-
withRequestCorrelation
default RestClient withRequestCorrelation(boolean hasRequestCorrelation)
- Specified by:
withRequestCorrelation
in interfaceorg.refcodes.runtime.RequestCorrelation<RestClient>
-
withEnableRequestCorrelation
default RestClient withEnableRequestCorrelation()
- Specified by:
withEnableRequestCorrelation
in interfaceorg.refcodes.runtime.RequestCorrelation<RestClient>
-
withDisableRequestCorrelation
default RestClient withDisableRequestCorrelation()
- Specified by:
withDisableRequestCorrelation
in interfaceorg.refcodes.runtime.RequestCorrelation<RestClient>
-
-