com.atlassian.sal.api.net.Request.setEntity()方法的使用及代码示例

x33g5p2x  于2022-01-29 转载在 其他  
字(2.6k)|赞(0)|评价(0)|浏览(249)

本文整理了Java中com.atlassian.sal.api.net.Request.setEntity方法的一些代码示例,展示了Request.setEntity的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Request.setEntity方法的具体详情如下:
包路径:com.atlassian.sal.api.net.Request
类名称:Request
方法名:setEntity

Request.setEntity介绍

暂无

代码示例

代码示例来源:origin: com.atlassian.applinks/applinks-plugin-core

public ApplicationLinkRequest setEntity(final Object entity)
{
  return setDelegate(request.setEntity(entity));
}

代码示例来源:origin: com.atlassian.applinks/applinks-common

public ApplicationLinkRequest setEntity(final Object entity) {
  return setDelegate(request.setEntity(entity));
}

代码示例来源:origin: com.atlassian.applinks/applinks-common

@SuppressWarnings("unchecked")
private void setRemoteStatus(ApplinkOAuthStatus status, ApplicationLink applink, RequestFactoryAdapter requestFactoryAdapter)
    throws ResponseException, CredentialsRequiredException {
  createDefaultJsonRequest(requestFactoryAdapter, MethodType.PUT, getStatusResourceUrl(applink))
      .setEntity(new RestApplinkOAuthStatus(status))
      .executeAndReturn(LoggingReturningResponseHandler.INSTANCE);
}

代码示例来源:origin: com.atlassian.applinks/applinks-common

private void remoteEnableUsingAuthenticationApi(OAuthConfig incoming,
                        OAuthConfig outgoing,
                        ApplicationLink applink,
                        RequestFactoryAdapter requestFactoryAdapter,
                        RemoteApplicationCapabilities capabilities)
    throws AuthenticationConfigurationException {
  try {
    // enable consumer (incoming)
    if (incoming.isEnabled()) {
      createDefaultJsonRequest(requestFactoryAdapter, MethodType.PUT, getAuthenticationConsumerResourceUrl(applink, capabilities))
          .setEntity(getRestConsumer(incoming))
          .executeAndReturn(LoggingReturningResponseHandler.INSTANCE);
    }
    if (outgoing.isEnabled()) {
      String authenticationProviderUrl = getAuthenticationProviderResourceUrl(applink);
      // enable providers (outgoing)
      for (Class<? extends AuthenticationProvider> providerClass : getProviders(outgoing)) {
        createDefaultJsonRequest(requestFactoryAdapter, MethodType.PUT, authenticationProviderUrl)
            .setEntity(new RestAuthenticationProvider(providerClass))
            .executeAndReturn(LoggingReturningResponseHandler.INSTANCE);
      }
    }
  } catch (ResponseException | CredentialsRequiredException e) {
    throw new AuthenticationConfigurationException(e);
  }
}

代码示例来源:origin: com.atlassian.applinks/applinks-plugin

.toString());
createLinkBackRequest.setEntity(linkBack);

代码示例来源:origin: com.atlassian.applinks/applinks-plugin

.setEntity(linkBackToMyself)
.executeAndReturn(new ReturningResponseHandler<Response, ErrorListEntity>() {
  public ErrorListEntity handle(final Response response) throws ResponseException {

代码示例来源:origin: com.atlassian.applinks/applinks-plugin

createSelfLinkFor(internalHostApplication.getId()));
createTwoWayLinkRequest.setEntity(linkBackToMyself);

相关文章