Class AbstractRemoteService<P>

java.lang.Object
com.atlassian.confluence.rest.client.AbstractRemoteService<P>
Type Parameters:
P - - the interface of the local service that this is a remote service of, used by RemoteServiceProxyCreator
Direct Known Subclasses:
AbstractRemoteChildContentService, AbstractRemoteChildContentService.AbstractRemoteChildContentFinder, AbstractRemoteContentLabelService, AbstractRemoteContentService, AbstractRemoteContentService.AbstractRemoteContentFinder, AbstractRemoteWebView, AbstractRemoteWebViewService, RemoteAccessModeServiceImpl, RemoteAttachmentServiceImpl, RemoteAttachmentServiceImpl.RemoteAttachmentFinderImpl, RemoteCategoryServiceImpl, RemoteClusterServiceImpl, RemoteContentBlueprintServiceImpl, RemoteContentBodyConversionServiceImpl, RemoteContentDraftServiceImpl, RemoteContentMacroServiceImpl, RemoteContentMacroServiceImpl.RemoteMacroFinderImpl, RemoteContentPropertyServiceImpl, RemoteContentPropertyServiceImpl.RemoteContentPropertyFinderImpl, RemoteContentRestrictionServiceImpl, RemoteContentTemplateServiceImpl, RemoteContentTemplateServiceImpl.RemoteTemplateFinderImpl, RemoteContentTrashServiceImpl, RemoteContentVersionServiceImpl, RemoteContentVersionServiceImpl.RemoteVersionFinderImpl, RemoteCQLSearchServiceImpl, RemoteGlobalColorSchemeServiceImpl, RemoteGlobalPermissionServiceImpl, RemoteGroupServiceImpl, RemoteGroupServiceImpl.RemoteGroupFinderImpl, RemoteInstanceMetricsServiceImpl, RemoteLabelServiceImpl, RemoteLongTaskServiceImpl, RemotePersonServiceImpl, RemotePersonServiceImpl.RemotePersonFinderImpl, RemoteRelationServiceImpl, RemoteServerInformationServiceImpl, RemoteSpaceColorSchemeServiceImpl, RemoteSpacePermissionServiceImpl, RemoteSpacePropertyServiceImpl, RemoteSpacePropertyServiceImpl.RemoteSpacePropertyFinderImpl, RemoteSpaceServiceImpl, RemoteSpaceServiceImpl.RemoteSpaceContentFinderImpl, RemoteSpaceServiceImpl.RemoteSpaceFinderImpl, RemoteWatchServiceImpl

public abstract class AbstractRemoteService<P> extends Object
Common parent class of all Confluence API Remote Service implementations, handling authentication and REST infrastructure.
Since:
9.0.1
  • Field Details

  • Constructor Details

  • Method Details

    • getExecutor

      protected ExecutorService getExecutor()
    • newWebTarget

      protected javax.ws.rs.client.WebTarget newWebTarget()
    • newExperimentalRestWebTarget

      protected javax.ws.rs.client.WebTarget newExperimentalRestWebTarget()
    • getCompletionStage

      protected <T> CompletionStage<T> getCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<? extends T> entityClass)
      Since:
      9.0
    • getCompletionStageOptional

      protected <T> CompletionStage<Optional<T>> getCompletionStageOptional(javax.ws.rs.client.WebTarget webTarget, Class<? extends T> entityClass)
      Since:
      9.0
    • getCompletionStagePageResponseList

      protected <E> CompletionStage<PageResponse<E>> getCompletionStagePageResponseList(javax.ws.rs.client.WebTarget webTarget, Class<E> contentClass)
      Since:
      9.0
    • getCompletionStageSearchPageResponseList

      protected <E> CompletionStage<SearchPageResponse<E>> getCompletionStageSearchPageResponseList(javax.ws.rs.client.WebTarget webTarget, Class<E> contentClass)
      Since:
      9.0
    • getCompletionStageMapOfPageResponses

      protected <K, V> CompletionStage<Map<K,PageResponse<V>>> getCompletionStageMapOfPageResponses(javax.ws.rs.client.WebTarget webTarget, Class<K> keyClass, Class<V> listContentClass)
      Since:
      9.0
    • getCompletionStageMapOfGenericListResponse

      protected <K, V> CompletionStage<Map<K,List<V>>> getCompletionStageMapOfGenericListResponse(javax.ws.rs.client.WebTarget resource, Class<K> keyClass, Class<V> listContentClass)
      Since:
      9.2.5
    • getCompletionStageMap

      protected <K, V> CompletionStage<Map<K,V>> getCompletionStageMap(javax.ws.rs.client.WebTarget webTarget, Class<K> keyClass, Class<V> valueClass)
      Since:
      9.0
    • getCompletionStageGenericCollection

      protected <E> CompletionStage<Iterable<E>> getCompletionStageGenericCollection(javax.ws.rs.client.WebTarget webTarget, Class<? extends Iterable> collectionType, Class<E> contentType)
      Since:
      9.0
    • postCompletionStage

      protected <E> CompletionStage<E> postCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<? extends E> entityClass, @Nullable Object postEntity)
      Since:
      9.0
    • postCompletionStage

      protected <E> CompletionStage<E> postCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<? extends E> entityClass, @Nullable Object postEntity, javax.ws.rs.core.MediaType mediaType)
      Since:
      9.0
    • postVoidCompletionStage

      protected CompletionStage<Void> postVoidCompletionStage(javax.ws.rs.client.WebTarget webTarget, @Nullable Object postEntity)
      Since:
      9.0
    • postCompletionStage

      protected <E> CompletionStage<E> postCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<E> collectionClass, Class contentType, Object postEntity)
      Since:
      9.0
    • postCompletionStageToPageResponse

      protected <T> CompletionStage<PageResponse<T>> postCompletionStageToPageResponse(javax.ws.rs.client.WebTarget webTarget, Class<T> entityClass, Object postEntity, javax.ws.rs.core.MediaType mediaType)
      Since:
      9.0
    • putCompletionStage

      protected <T> CompletionStage<T> putCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<? extends T> responseEntityClass, @Nullable Object putEntity)
      Since:
      9.0
    • putVoidCompletionStage

      protected CompletionStage<Void> putVoidCompletionStage(javax.ws.rs.client.WebTarget webTarget, @Nullable Object putEntity)
      Since:
      9.1
    • deleteCompletionStage

      protected CompletionStage<Void> deleteCompletionStage(javax.ws.rs.client.WebTarget webTarget)
      Since:
      9.0
    • deleteCompletionStage

      protected <T> CompletionStage<T> deleteCompletionStage(javax.ws.rs.client.WebTarget webTarget, Class<? extends T> responseClass)
      Since:
      9.0
    • addExpansions

      protected javax.ws.rs.client.WebTarget addExpansions(javax.ws.rs.client.WebTarget webTarget, @Nullable Expansion[] expansions)
      add the expansions to the WebTarget as a query param, this specifies which properties on the results to expand
      Parameters:
      webTarget - - the WebTarget to add the query param to, a copy of this webTarget will be returned
      expansions - - the expansions to add
      Returns:
      a new WebTarget with the expansions added to it
    • addPageRequestParams

      protected javax.ws.rs.client.WebTarget addPageRequestParams(javax.ws.rs.client.WebTarget webTarget, @Nullable PageRequest request)
      Adds start and limit query params to honour the pageRequest values
      Parameters:
      webTarget - - the webTarget to add the query params to
      request - - the pageRequest supplying the values for the query params, may be null
    • addPageRequest

      protected javax.ws.rs.client.WebTarget addPageRequest(javax.ws.rs.client.WebTarget webTarget, PageRequest pageRequest)