Examples of IPlatformFactory


Examples of com.ibm.commons.platform.IPlatformFactory

        try {
            List<Object> l = ExtensionManager.findServices(null, Platform.class, FACTORY_CLASS);
            if(l.size()>0) {
                // Only get the first one...
              try {
                  IPlatformFactory factory = (IPlatformFactory)l.get(0);
                  return factory.createPlatform();
              } catch(Throwable e) {
                  e.printStackTrace();
              }
            }
        } catch(Throwable e) {
            // Not found...
        }
        // 2+- Try to find a factory with fixed name
        // This is left temporally as it won't be in use when the Domino server will be restructured
        try {
            Class<?> factoryClass = Class.forName(FACTORY_CLASS); // $NON-NLS-1$
            try {
                IPlatformFactory factory = (IPlatformFactory)factoryClass.newInstance();
                return factory.createPlatform();
            } catch(Throwable e) {
                e.printStackTrace();
            }
        } catch(Throwable e) {
            // Not found...
View Full Code Here

Examples of com.ibm.commons.platform.IPlatformFactory

        // If so, use an extension point to get the actual registered platform
        if( tryClass("org.eclipse.core.runtime.Platform") ) { // $NON-NLS-1$
            // We do a dynamic class loading to ensure that there is no hard-links to the class
            try {
                Class<?> c = Class.forName("com.ibm.commons.platform.EclipsePlatformFactory"); // $NON-NLS-1$
                IPlatformFactory factory = (IPlatformFactory)c.newInstance();
                return factory.createPlatform();
            } catch(Throwable e) {
                e.printStackTrace();
            }
           
            // Generic Eclipse
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.