当前位置: 首页>>代码示例>>Java>>正文


Java NamedXContentRegistry.EMPTY属性代码示例

本文整理汇总了Java中org.elasticsearch.common.xcontent.NamedXContentRegistry.EMPTY属性的典型用法代码示例。如果您正苦于以下问题:Java NamedXContentRegistry.EMPTY属性的具体用法?Java NamedXContentRegistry.EMPTY怎么用?Java NamedXContentRegistry.EMPTY使用的例子?那么, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在org.elasticsearch.common.xcontent.NamedXContentRegistry的用法示例。


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

示例1: azureRepository

private AzureRepository azureRepository(Settings settings) throws StorageException, IOException, URISyntaxException {
    Settings internalSettings = Settings.builder()
        .put(Environment.PATH_HOME_SETTING.getKey(), createTempDir().toAbsolutePath())
        .putArray(Environment.PATH_DATA_SETTING.getKey(), tmpPaths())
        .put(settings)
        .build();
    return new AzureRepository(new RepositoryMetaData("foo", "azure", internalSettings), new Environment(internalSettings),
        NamedXContentRegistry.EMPTY, null);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:9,代码来源:AzureRepositorySettingsTests.java

示例2: FakeRestRequest

public FakeRestRequest() {
    this(NamedXContentRegistry.EMPTY, new HashMap<>(), new HashMap<>(), null, Method.GET, "/", null);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:3,代码来源:FakeRestRequest.java

示例3: ContentRestRequest

ContentRestRequest(String content, Map<String, String> params, Map<String, List<String>> headers) {
    super(NamedXContentRegistry.EMPTY, params, "not used by this test", headers);
    this.content = new BytesArray(content);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:4,代码来源:RestRequestTests.java

示例4: TestRestRequest

private TestRestRequest(String path, String content, XContentType xContentType) {
    super(NamedXContentRegistry.EMPTY, Collections.emptyMap(), path, xContentType == null ?
        Collections.emptyMap() : Collections.singletonMap("Content-Type", Collections.singletonList(xContentType.mediaType())));
    this.content = new BytesArray(content);
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:5,代码来源:RestControllerTests.java

示例5: assertValidBuffer

private void assertValidBuffer(long bufferMB, long chunkMB) throws IOException {
    RepositoryMetaData metadata = new RepositoryMetaData("dummy-repo", "mock", Settings.builder()
        .put(Repository.BUFFER_SIZE_SETTING.getKey(), new ByteSizeValue(bufferMB, ByteSizeUnit.MB))
        .put(Repository.CHUNK_SIZE_SETTING.getKey(), new ByteSizeValue(chunkMB, ByteSizeUnit.MB)).build());
    new S3Repository(metadata, Settings.EMPTY, NamedXContentRegistry.EMPTY, new DummyS3Service());
}
 
开发者ID:justor,项目名称:elasticsearch_my,代码行数:6,代码来源:S3RepositoryTests.java


注:本文中的org.elasticsearch.common.xcontent.NamedXContentRegistry.EMPTY属性示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。