com.microsoft.azure.management.Azure.configure()方法的使用及代码示例

x33g5p2x  于2022-01-17 转载在 其他  
字(1.9k)|赞(0)|评价(0)|浏览(181)

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

Azure.configure介绍

暂无

代码示例

代码示例来源:origin: Microsoft/azure-maven-plugins

protected Azure.Configurable azureConfigure() {
  final String httpProxyHost = config.getHttpProxyHost();
  final int httpProxyPort = config.getHttpProxyPort();
  final Azure.Configurable configurable = Azure.configure()
      .withLogLevel(getLogLevel())
      .withUserAgent(config.getUserAgent());
  return StringUtils.isNotEmpty(httpProxyHost) ?
    configurable.withProxy(new Proxy(Proxy.Type.HTTP, new InetSocketAddress(httpProxyHost, httpProxyPort))) :
    configurable;                      
}

代码示例来源:origin: com.microsoft.azure/azure-maven-plugin-lib

protected Azure.Configurable azureConfigure() {
  final String httpProxyHost = config.getHttpProxyHost();
  final int httpProxyPort = config.getHttpProxyPort();
  final Azure.Configurable configurable = Azure.configure()
      .withLogLevel(getLogLevel())
      .withUserAgent(config.getUserAgent());
  return StringUtils.isNotEmpty(httpProxyHost) ?
    configurable.withProxy(new Proxy(Proxy.Type.HTTP, new InetSocketAddress(httpProxyHost, httpProxyPort))) :
    configurable;                      
}

代码示例来源:origin: Microsoft/azure-tools-for-java

private Azure.Authenticated auth() throws IOException {
  Azure.Configurable azureConfigurable = Azure.configure()
        .withInterceptor(new TelemetryInterceptor())
        .withUserAgent(CommonSettings.USER_AGENT);
  return (atc == null)
      ? azureConfigurable.authenticate(credFile)
      : azureConfigurable.authenticate(atc);
}

代码示例来源:origin: Microsoft/azure-tools-for-java

private static Azure.Authenticated authTid(String tid) throws IOException {
//        String token = AdAuthManager.getInstance().getAccessToken(tid);
//        return auth(token);
    return Azure.configure()
        .withInterceptor(new TelemetryInterceptor())
        .withUserAgent(CommonSettings.USER_AGENT).authenticate(new RefreshableTokenCredentials(AdAuthManager.getInstance(), tid));
  }

相关文章