gpt4 book ai didi

org.jclouds.byon.config.YamlNodeStoreModule.bind()方法的使用及代码示例

转载 作者:知者 更新时间:2024-03-14 09:43:31 25 4
gpt4 key购买 nike

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

YamlNodeStoreModule.bind介绍

暂无

代码示例

代码示例来源:origin: org.apache.jclouds.api/byon

@Override
protected void configure() {
 bind(new TypeLiteral<Supplier<LoadingCache<String, Node>>>() {
 }).to(NodesParsedFromSupplier.class);
 bind(new TypeLiteral<Function<ByteSource, LoadingCache<String, Node>>>() {
 }).to(NodesFromYamlStream.class);
 bind(new TypeLiteral<Function<YamlNode, ByteSource>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.yamlNodeToByteSource);
 bind(new TypeLiteral<Function<ByteSource, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.byteSourceToYamlNode);
 bind(new TypeLiteral<Function<Node, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.nodeToYamlNode);
 bind(new TypeLiteral<Function<YamlNode, Node>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.toNode);
 if (backing != null) {
   bind(new TypeLiteral<Map<String, ByteSource>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(backing);
 } else {
   bind(new TypeLiteral<Map<String, ByteSource>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(BACKING);
 }
}

代码示例来源:origin: jclouds/legacy-jclouds

@Override
protected void configure() {
 bind(new TypeLiteral<Supplier<LoadingCache<String, Node>>>() {
 }).to(NodesParsedFromSupplier.class);
 bind(new TypeLiteral<Function<InputStream, LoadingCache<String, Node>>>() {
 }).to(NodesFromYamlStream.class);
 bind(new TypeLiteral<Function<YamlNode, InputStream>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.yamlNodeToInputStream);
 bind(new TypeLiteral<Function<InputStream, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.inputStreamToYamlNode);
 bind(new TypeLiteral<Function<Node, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.nodeToYamlNode);
 bind(new TypeLiteral<Function<YamlNode, Node>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.toNode);
 if (backing != null) {
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(backing);
 } else {
   bind(new TypeLiteral<Map<String, InputSupplier<InputStream>>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(BACKING);
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).to(new TypeLiteral<YAMLCopyInputStreamInputSupplierMap>() {
   });
 }
}

代码示例来源:origin: apache/jclouds

@Override
protected void configure() {
 bind(new TypeLiteral<Supplier<LoadingCache<String, Node>>>() {
 }).to(NodesParsedFromSupplier.class);
 bind(new TypeLiteral<Function<ByteSource, LoadingCache<String, Node>>>() {
 }).to(NodesFromYamlStream.class);
 bind(new TypeLiteral<Function<YamlNode, ByteSource>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.yamlNodeToByteSource);
 bind(new TypeLiteral<Function<ByteSource, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.byteSourceToYamlNode);
 bind(new TypeLiteral<Function<Node, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.nodeToYamlNode);
 bind(new TypeLiteral<Function<YamlNode, Node>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.toNode);
 if (backing != null) {
   bind(new TypeLiteral<Map<String, ByteSource>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(backing);
 } else {
   bind(new TypeLiteral<Map<String, ByteSource>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(BACKING);
 }
}

代码示例来源:origin: org.jclouds.api/byon

@Override
protected void configure() {
 bind(new TypeLiteral<Supplier<LoadingCache<String, Node>>>() {
 }).to(NodesParsedFromSupplier.class);
 bind(new TypeLiteral<Function<InputStream, LoadingCache<String, Node>>>() {
 }).to(NodesFromYamlStream.class);
 bind(new TypeLiteral<Function<YamlNode, InputStream>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.yamlNodeToInputStream);
 bind(new TypeLiteral<Function<InputStream, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.inputStreamToYamlNode);
 bind(new TypeLiteral<Function<Node, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.nodeToYamlNode);
 bind(new TypeLiteral<Function<YamlNode, Node>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.toNode);
 if (backing != null) {
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(backing);
 } else {
   bind(new TypeLiteral<Map<String, InputSupplier<InputStream>>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(BACKING);
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).to(new TypeLiteral<YAMLCopyInputStreamInputSupplierMap>() {
   });
 }
}

代码示例来源:origin: io.cloudsoft.jclouds.api/byon

@Override
protected void configure() {
 bind(new TypeLiteral<Supplier<LoadingCache<String, Node>>>() {
 }).to(NodesParsedFromSupplier.class);
 bind(new TypeLiteral<Function<InputStream, LoadingCache<String, Node>>>() {
 }).to(NodesFromYamlStream.class);
 bind(new TypeLiteral<Function<YamlNode, InputStream>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.yamlNodeToInputStream);
 bind(new TypeLiteral<Function<InputStream, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.inputStreamToYamlNode);
 bind(new TypeLiteral<Function<Node, YamlNode>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.nodeToYamlNode);
 bind(new TypeLiteral<Function<YamlNode, Node>>() {
 }).toInstance(org.jclouds.byon.domain.YamlNode.toNode);
 if (backing != null) {
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(backing);
 } else {
   bind(new TypeLiteral<Map<String, InputSupplier<InputStream>>>() {
   }).annotatedWith(Names.named("yaml")).toInstance(BACKING);
   bind(new TypeLiteral<Map<String, InputStream>>() {
   }).annotatedWith(Names.named("yaml")).to(new TypeLiteral<YAMLCopyInputStreamInputSupplierMap>() {
   });
 }
}

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com