/* * (non-Javadoc) * @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext) */ public void start(BundleContext context) throws Exception { // Print a session logging header. getLog().log(new Status(IStatus.OK, "Starting RAMSES plugin suite ...", "RAMSES starting ...")); ; // Set the level to FATAL for the plugin activation. Later, RAMSES will // will set the level to the user configuration. String lvl = "FATAL"; RamsesConfiguration.setupLogging(lvl, Platform.getLogFileLocation().toFile(), false); try { super.start(context); plugin = this; /** * **** Always set Ramses resouce dirs before initialize Service Registry, instantiator and * AADL models manager !!! *************************** */ WorkbenchUtils.setResourceDirectories(); // MessageReporter4Osate msgReporter = new MessageReporter4Osate() ; // ServiceProvider.SYS_ERR_REP = new SysErrReporter4Osate(msgReporter) ; ServiceRegistry sr = new OSGiServiceRegistry(); AadlModelInstantiatior instantiator; instantiator = new AadlModelsManagerImpl(ServiceRegistry.ANALYSIS_ERR_REPORTER_MANAGER); PredefinedAadlModelManager modelManager; // modelManager = new ContributedAadlRegistration() ; // sr.init(instantiator, modelManager); ServiceProvider.setDefault(sr); /** *********************************************************************** */ } catch (Exception e) // Top level exception handler. Stop all process. { Logger.getLogger(Activator.class).fatal("", e); ServiceProvider.SYS_ERR_REP.fatal("", e); } }