• 如果您觉得本站非常有看点,那么赶紧使用Ctrl+D 收藏吧

Java ConnectionConfigImpl类的典型用法和代码示例

java 1次浏览

本文整理汇总了Java中org.apache.calcite.avatica.ConnectionConfigImpl的典型用法代码示例。如果您正苦于以下问题:Java ConnectionConfigImpl类的具体用法?Java ConnectionConfigImpl怎么用?Java ConnectionConfigImpl使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。

ConnectionConfigImpl类属于org.apache.calcite.avatica包,在下文中一共展示了ConnectionConfigImpl类的3个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: testDefaultHttpClient

点赞 2

import org.apache.calcite.avatica.ConnectionConfigImpl; //导入依赖的package包/类
@Test public void testDefaultHttpClient() throws Exception {
  Properties props = new Properties();
  URL url = new URL("http://localhost:8765");
  ConnectionConfig config = new ConnectionConfigImpl(props);
  AvaticaHttpClientFactory httpClientFactory = new AvaticaHttpClientFactoryImpl();

  AvaticaHttpClient client = httpClientFactory.getClient(url, config, null);
  assertTrue("Client was an instance of " + client.getClass(),
      client instanceof AvaticaCommonsHttpClientImpl);
}
 

开发者ID:apache,
项目名称:calcite-avatica,
代码行数:11,
代码来源:AvaticaHttpClientFactoryTest.java

示例2: testOverridenHttpClient

点赞 2

import org.apache.calcite.avatica.ConnectionConfigImpl; //导入依赖的package包/类
@Test public void testOverridenHttpClient() throws Exception {
  Properties props = new Properties();
  props.setProperty(BuiltInConnectionProperty.HTTP_CLIENT_IMPL.name(),
      AvaticaHttpClientImpl.class.getName());
  URL url = new URL("http://localhost:8765");
  ConnectionConfig config = new ConnectionConfigImpl(props);
  AvaticaHttpClientFactory httpClientFactory = new AvaticaHttpClientFactoryImpl();

  AvaticaHttpClient client = httpClientFactory.getClient(url, config, null);
  assertTrue("Client was an instance of " + client.getClass(),
      client instanceof AvaticaHttpClientImpl);
}
 

开发者ID:apache,
项目名称:calcite-avatica,
代码行数:13,
代码来源:AvaticaHttpClientFactoryTest.java

示例3: wrap

点赞 2

import org.apache.calcite.avatica.ConnectionConfigImpl; //导入依赖的package包/类
public ConnectionConfigImpl.PropEnv wrap(Properties properties) {
  final HashMap<String, ConnectionProperty> map = new HashMap<>();
  map.put(name, this);
  return new ConnectionConfigImpl.PropEnv(
      ConnectionConfigImpl.parse(properties, map), this);
}
 

开发者ID:apache,
项目名称:calcite-avatica,
代码行数:7,
代码来源:AvaticaUtilsTest.java


版权声明:本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系管理员进行删除。
喜欢 (0)