01: package fr.aliacom.form.common;
02:
03: import fr.aliacom.common.ui.ISplashScreen;
04: import fr.aliacom.form.storage.IFormRepository;
05: import fr.aliacom.form.storage.IIconRepository;
06: import fr.aliacom.form.storage.IScriptRepository;
07:
08: /**
09: * An implementation of this class is needed to start the form
10: * framework.
11: *
12: * When the <code>Toolkit</code> starts an application, the
13: * methods are called in the following order:
14: * <ul>
15: * <li><code>getFormRepository()</code></li>
16: * <li><code>getIconRepository()</code></li>
17: * <li><code>getScriptRepository()</code></li>
18: * <li><code>getSlashIconName()</code></li>
19: * <li><code>getSplashSteps()</code></li>
20: * <li><code>getStartupContext()</code></li>
21: * <li><code>getMainWindowFormName()</code></li>
22: * <li><code>getIconName()</code></li>
23: * </ul>
24: *
25: * When the UI is realized on screen, the toolkit calls the
26: * <code>mainWindowRealized(IForm mainWindow)</code> method
27: * from the ui thread.
28: *
29: * Once the last opened form is closed, the toolkit calls the stop
30: * method.
31: *
32: * @author tom
33: *
34: * $Id: IApplication.java,v 1.3 2003/03/13 00:49:42 tcataldo Exp $
35: */
36: public interface IApplication {
37:
38: IFormRepository getFormRepository();
39:
40: IIconRepository getIconRepository();
41:
42: IScriptRepository getScriptRepository();
43:
44: String getStartupFormName();
45:
46: String getSplashIconName();
47:
48: int getSplashSteps();
49:
50: FormContext getStartupContext(ISplashScreen splash);
51:
52: void stop();
53:
54: /**
55: * The icon used in the operating system taskbar
56: * to represent the application.
57: *
58: * This icon is loaded from the IIconRepository provided.
59: *
60: * @return the name of the icon.
61: */
62: String getIconName();
63:
64: /**
65: * Called from the ui thread.
66: *
67: * @param mainWindow
68: */
69: void mainWindowRealized(IForm mainWindow);
70:
71: }
|