setAppStatus(EclipseAppHandle.STOPPED);
setAppStatus(EclipseAppHandle.FLAG_STOPPED);
	public Object run(Object context) throws Exception {		if (context != null) {			// always force the use of the context if it is not null			arguments.put(IApplicationContext.APPLICATION_ARGS, context);		} else {			// get the context from the arguments			context = arguments.get(IApplicationContext.APPLICATION_ARGS);			if (context == null) {				// if context is null then use the args from CommandLineArgs				context = CommandLineArgs.getApplicationArgs();				arguments.put(IApplicationContext.APPLICATION_ARGS, context);			}		}		Object result;		try {			Object app;			synchronized (this) {				application = getConfiguration().createExecutableExtension("run"); //$NON-NLS-1$				app = application;			}			if (app instanceof IApplication)				result = ((IApplication) app).start(this);			else				result = ((IPlatformRunnable) app).run(context);		} finally {			synchronized (this) {				application = null;			}			// The application exited itself; notify the app context			setAppStatus(EclipseAppHandle.STOPPED);		}		int exitCode = result instanceof Integer ? ((Integer) result).intValue() : 0;		// use the long way to set the property to compile against eeminimum		System.getProperties().setProperty(PROP_ECLIPSE_EXITCODE, Integer.toString(exitCode));		if (Activator.DEBUG)			System.out.println(NLS.bind(Messages.application_returned, (new String[] {getApplicationDescriptor().getApplicationId(), result == null ? "null" : result.toString()}))); //$NON-NLS-1$		return result;	}