use of com.liferay.ide.server.core.portal.AbstractPortalBundleFactory in project liferay-ide by liferay.
the class LiferayServerCore method getPortalBundleFactories.
public static PortalBundleFactory[] getPortalBundleFactories() {
if (portalBundleFactories == null) {
final IConfigurationElement[] elements = Platform.getExtensionRegistry().getConfigurationElementsFor(PortalBundleFactory.EXTENSION_ID);
try {
final List<PortalBundleFactory> bundleFactories = new ArrayList<PortalBundleFactory>();
for (IConfigurationElement element : elements) {
final Object o = element.createExecutableExtension("class");
if (o instanceof PortalBundleFactory) {
AbstractPortalBundleFactory portalBundleFactory = (AbstractPortalBundleFactory) o;
portalBundleFactory.setBundleFactoryType(element.getAttribute("type"));
bundleFactories.add(portalBundleFactory);
}
}
portalBundleFactories = bundleFactories.toArray(new PortalBundleFactory[0]);
} catch (Exception e) {
// $NON-NLS-1$
logError("Unable to get PortalBundleFactory extensions", e);
}
}
return portalBundleFactories;
}
Aggregations