本文整理了Java中org.elasticsearch.common.inject.Key.equals()
方法的一些代码示例,展示了Key.equals()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Key.equals()
方法的具体详情如下:
包路径:org.elasticsearch.common.inject.Key
类名称:Key
方法名:equals
暂无
代码示例来源:origin: org.elasticsearch/elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMapBinder
&& ((RealMapBinder<?, ?>) o).mapKey.equals(mapKey);
}
代码示例来源:origin: org.elasticsearch/elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMultibinder
&& ((RealMultibinder<?>) o).setKey.equals(setKey);
}
代码示例来源:origin: org.elasticsearch/elasticsearch
@Override
public Void visit(LinkedKeyBinding<? extends T> binding) {
Key<? extends T> linkedKey = binding.getLinkedKey();
if (key.equals(linkedKey)) {
errors.recursiveBinding();
}
FactoryProxy<T> factory = new FactoryProxy<>(injector, key, linkedKey, source);
creationListeners.add(factory);
InternalFactory<? extends T> scopedFactory = Scopes.scope(key, injector, factory, scoping);
putBinding(
new LinkedBindingImpl<>(injector, key, source, scopedFactory, scoping, linkedKey));
return null;
}
代码示例来源:origin: com.strapdata.elasticsearch/elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMapBinder
&& ((RealMapBinder<?, ?>) o).mapKey.equals(mapKey);
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMapBinder
&& ((RealMapBinder<?, ?>) o).mapKey.equals(mapKey);
}
代码示例来源:origin: harbby/presto-connectors
@Override
public boolean equals(Object o) {
return o instanceof RealMultibinder
&& ((RealMultibinder<?>) o).setKey.equals(setKey);
}
代码示例来源:origin: apache/servicemix-bundles
@Override
public boolean equals(Object o) {
return o instanceof RealMultibinder
&& ((RealMultibinder<?>) o).setKey.equals(setKey);
}
代码示例来源:origin: apache/servicemix-bundles
@Override
public boolean equals(Object o) {
return o instanceof RealMapBinder
&& ((RealMapBinder<?, ?>) o).mapKey.equals(mapKey);
}
代码示例来源:origin: com.strapdata.elasticsearch/elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMultibinder
&& ((RealMultibinder<?>) o).setKey.equals(setKey);
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch
@Override
public boolean equals(Object o) {
return o instanceof RealMultibinder
&& ((RealMultibinder<?>) o).setKey.equals(setKey);
}
代码示例来源:origin: harbby/presto-connectors
@Override
public boolean equals(Object o) {
return o instanceof RealMapBinder
&& ((RealMapBinder<?, ?>) o).mapKey.equals(mapKey);
}
代码示例来源:origin: com.strapdata.elasticsearch/elasticsearch
@Override
public Void visit(LinkedKeyBinding<? extends T> binding) {
Key<? extends T> linkedKey = binding.getLinkedKey();
if (key.equals(linkedKey)) {
errors.recursiveBinding();
}
FactoryProxy<T> factory = new FactoryProxy<>(injector, key, linkedKey, source);
creationListeners.add(factory);
InternalFactory<? extends T> scopedFactory = Scopes.scope(key, injector, factory, scoping);
putBinding(
new LinkedBindingImpl<>(injector, key, source, scopedFactory, scoping, linkedKey));
return null;
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.elasticsearch
@Override
public Void visit(LinkedKeyBinding<? extends T> binding) {
Key<? extends T> linkedKey = binding.getLinkedKey();
if (key.equals(linkedKey)) {
errors.recursiveBinding();
}
FactoryProxy<T> factory = new FactoryProxy<>(injector, key, linkedKey, source);
creationListeners.add(factory);
InternalFactory<? extends T> scopedFactory = Scopes.scope(key, injector, factory, scoping);
putBinding(
new LinkedBindingImpl<>(injector, key, source, scopedFactory, scoping, linkedKey));
return null;
}
代码示例来源:origin: harbby/presto-connectors
@Override
public Void visit(LinkedKeyBinding<? extends T> binding) {
Key<? extends T> linkedKey = binding.getLinkedKey();
if (key.equals(linkedKey)) {
errors.recursiveBinding();
}
FactoryProxy<T> factory = new FactoryProxy<>(injector, key, linkedKey, source);
creationListeners.add(factory);
InternalFactory<? extends T> scopedFactory = Scopes.scope(key, injector, factory, scoping);
putBinding(
new LinkedBindingImpl<>(injector, key, source, scopedFactory, scoping, linkedKey));
return null;
}
代码示例来源:origin: apache/servicemix-bundles
@Override
public Void visit(LinkedKeyBinding<? extends T> binding) {
Key<? extends T> linkedKey = binding.getLinkedKey();
if (key.equals(linkedKey)) {
errors.recursiveBinding();
}
FactoryProxy<T> factory = new FactoryProxy<>(injector, key, linkedKey, source);
creationListeners.add(factory);
InternalFactory<? extends T> scopedFactory = Scopes.scope(key, injector, factory, scoping);
putBinding(
new LinkedBindingImpl<>(injector, key, source, scopedFactory, scoping, linkedKey));
return null;
}
代码示例来源:origin: harbby/presto-connectors
@Override
@SuppressWarnings("unchecked") // raw keys are necessary for the args array and return value
protected void configure() {
Binder binder = binder().withSource(method);
int p = 0;
for (Key<?> paramKey : paramTypes.get(method)) {
// Wrap in a Provider to cover null, and to prevent Guice from injecting the parameter
binder.bind((Key) paramKey).toProvider(Providers.of(args[p++]));
}
if (producedType != null && !returnType.equals(producedType)) {
binder.bind(returnType).to((Key) producedType);
} else {
binder.bind(returnType);
}
}
};
内容来源于网络,如有侵权,请联系作者删除!