The goal is to finalize the API and settle for naming and feature set. The documentation, both javadoc and otherwise also needs to be improved.
The current packaging needs to be rethought. This is to be tackled in a separate effort (See Concept - package reorganisation concretes).
We should finalize the API in terms of finding the right level of abstraction. The API should guide the app developer and not expose internals.
The framework is a set of interfaces and abstract utility classes that assist by implementing an app.
These interfaces and classes are in magnolia-ui-framework. The implementation AppController and the location handling are in magnolia-ui-admincentral.
From An App Developers perspective
Approved Steps currently in development
- Convert abstract *Apps (AbstractApp, AbstractSubApp, ...) to concrete classes (BaseApp, BaseSubApp, ...)
- Interface for AppFrameView (AppView), inject interface into BaseApp
- AppView.Listener implemented by AppContext -> listens to AppView events
- remove tab dependency from events
- Remove vaadin dependencies from AppContext
- Rename AppContextImpl ->AppInstanceControllerImpl
- AppInstanceControllerImpl implements two interfaces:
- AppContext for contextual information relevant for the app
- AppInstanceController exposing the contract to the AppController
- AppController: use AppDescriptorRegistry instead of AppLauncherLayoutManager
- should go
- Create app framework specific interfaces for e.g. AppView, SubAppView
- SubAppView interface is still missing
- stop method in subapp
- remove vaadin dependencies from magnolia-ui-framework
- Move info.magnolia.ui.framework.view.View into vaadin-integration
|Type||Location||Status Quo||Proposed Action|
|info.magnolia.ui.framework.app||abstract but many subclasses (e.g. PagesApp, MessagesApp) don't add additional functionality||convert to non-abstract type & rename to BaseApp. Get rid of most subclasses. Inject the AppContext and App(Frame)View directly into the AbstractApp instead of passing it from the AppClass.|
Used for opening the ChooseDialog. A relict from the time we had the workbench definition bound to the App.
Remove class and create an interface for ChooseDialog
The idea of this class was serving the workbench configuration, as this has moved to the subApp there is no real usage for this class. The logic in there for serving a ChooseDialog hould be moved to an interface, so that the actual implementation of opening the Dialog is up to the App and not bound to the framework.
|AbstractSubApp||info.magnolia.ui.framework.app||see AbstractApp||convert to non-abstract - e.g. PageMainSubApp could go|
|AbstractItemSubApp||info.magnolia.ui.admincentral.app.content||see AbstractApp||convert to non-abstract- e.g. ContactsItemSubApp could completely go then|
The App controller that manages the lifecycle of running apps and raises callbacks to the app.
The AppContext serves multiple different purposes:
The general problem: used heavily by the appController and also for the app itself to get contextual information: serving multiple needs. see
Should not be depending of any vaadin dependencies.
|SubApp||All SubApp's are considered to be equal. We can flag one (or even more) to be the default - that's the one that will be opened first and that won't be closable.|
|SubbAppContext||Basically in good shape - just offers a little too much.|
Eliminate methods only relevant for the implementing types - not for someone writing an app.
Basically we should question all setters on this interface.
|simply used for config|
|AppFrameView||info.magnolia.ui.admincentral.app.simple||Used to give Apps a consistent view. Holds a MagnoliaTabSheet and a Listener interface which makes the AppContext dependant on MagnoliaTabs.|
Thoughts from first review
- we should try to extract locationManagement
-> find better name, it's more than an Impl of an AppContext
-> one option (Tobias' propsal): rename AppController -> AppManager & AppContextImpl -> AppController
- only the AppLauncher should use it
5) structuring of modules: admin-central & framework: check whether AppContextImpl can to framework
-> frist streamline the interfaces
6) Should Main Subapp be an explicit type - we don't want to be able to overwrite.
7) Security App: this is the most exceptional one - will it be split into several apps or not? If yes, we could App Framework could be simplified even more
Espen & me will do some further investigations, prepare better concept with clear decision points and contact u again for review - we won't do any coding for before then.