本文整理了Java中org.jboss.weld.environment.se.Weld.loadExtensions()
方法的一些代码示例,展示了Weld.loadExtensions()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Weld.loadExtensions()
方法的具体详情如下:
包路径:org.jboss.weld.environment.se.Weld
类名称:Weld
方法名:loadExtensions
暂无
代码示例来源:origin: org.jboss.weld.se/weld-se
protected Iterable<Metadata<Extension>> getExtensions() {
Set<Metadata<Extension>> result = new HashSet<Metadata<Extension>>();
if (discoveryEnabled) {
Iterables.addAll(result, loadExtensions(resourceLoader));
}
if (!extensions.isEmpty()) {
result.addAll(extensions);
}
// Ensure that WeldSEBeanRegistrant is present
WeldSEBeanRegistrant weldSEBeanRegistrant = null;
for (Metadata<Extension> metadata : result) {
if (metadata.getValue().getClass().getName().equals(WeldSEBeanRegistrant.class.getName())) {
weldSEBeanRegistrant = (WeldSEBeanRegistrant) metadata.getValue();
break;
}
}
if (weldSEBeanRegistrant == null) {
try {
weldSEBeanRegistrant = SecurityActions.newInstance(WeldSEBeanRegistrant.class);
result.add(new MetadataImpl<Extension>(weldSEBeanRegistrant, SYNTHETIC_LOCATION_PREFIX + WeldSEBeanRegistrant.class.getName()));
} catch (Exception e) {
throw new RuntimeException(e);
}
}
if (isEnabled(DEV_MODE_SYSTEM_PROPERTY, false)) {
// The development mode is enabled - register the Probe extension
result.add(new MetadataImpl<Extension>(DevelopmentMode.getProbeExtension(resourceLoader), "N/A"));
}
return result;
}
代码示例来源:origin: weld/core
protected Iterable<Metadata<Extension>> getExtensions() {
Set<Metadata<Extension>> result = new HashSet<Metadata<Extension>>();
if (discoveryEnabled) {
Iterables.addAll(result, loadExtensions(resourceLoader));
代码示例来源:origin: weld/core
protected Iterable<Metadata<Extension>> getExtensions() {
Set<Metadata<Extension>> result = new HashSet<Metadata<Extension>>();
if (discoveryEnabled) {
Iterables.addAll(result, loadExtensions(resourceLoader));
代码示例来源:origin: org.jboss.weld.se/weld-se-shaded
protected Iterable<Metadata<Extension>> getExtensions() {
Set<Metadata<Extension>> result = new HashSet<Metadata<Extension>>();
if (discoveryEnabled) {
Iterables.addAll(result, loadExtensions(resourceLoader));
内容来源于网络,如有侵权,请联系作者删除!