New Layout: BAM Roadmap
Author: James Everingham
Updated: April 28, 1998
eds. note: BAM stands for "Born Again Modularization," not the Flintstones character.
Overview |
The goal of the BAM modularization
effort is to separate key modules for shared use by both NGLayout and the
5.0 code base. The BAM effort is driven by the need to integrate
the new NGLayout engine while achieving a more maintainable and modular
architecture. This will be achieved by targeting strategic
areas: the network support library (netlib), the layout engine
(layout), and the image library (imglib). The netlib effort
will involve breaking the current implementation into several different
DLLs and libraries, each of which will expose one or more XPCOM components.
The layout effort involves defining a set of layout specific XPCOM apis
(webwidget), and integration of the NGLayout engine into the current 5.0
source code base. Imglib separation includes defining an imglib
XPCOM interface and re-integration back into the 5.0 source code base.
Major Components |
Netlib
Netlib Engine DLLThis DLL will contain the core networking functionality including the networking utilities required by all consumers of Netlib. New code such as NGLayout will program directly to the new XPCOM APIs exposed by the engine.
Netlib Client static library
This library will contain the legacy code needed by the Mozilla client to utilize Netlib. Ultimately, this code should decrease as more and more of the client is reworked to utilize the new XPCOM APIs...
Streams DLL
This DLL will contain the various stream implementations used by Netlib...
Netlib Protocol DLLs
The protocols supported by Netlib will be broken out into separate dynamically loaded DLLs. This will allow new protocols to be dynamically added.
Implementation |
During the BAM process, the two code
bases will be in the following states:
5.0 Source Base | NGLayout Source Base |
integrated imagelib
integrated netlib integrated layout |
modular layout integrated into standalone
test suite
modular netlib modular imglib |
modular imagelib
integrated netlib integrated layout |
modular layout integrated into standalone
test suite
modular netlib modular imglib |
modular imagelib
modular netlib integrated layout |
modular layout integrated into standalone
test suite and 5.0 source base
modular netlib modular imglib |
modular imagelib
modular netlib modular layout |
modular imagelib
modular netlib modular layout |
Below is the proposed directory structure
of the Netlib code.
Directory | Description |
mozilla/network | The root networking directory |
mozilla/network/protocols | The root directory for all protocol implementations |
mozilla/network/protocols/<your favorite protocol implementation> | There is a directory per protocol implementation |
mozilla/network/engine | The core Netlib implementation |
mozilla/network/client | The legacy code needed by the Mozilla client... |
mozilla/network/stream | The implementations of various streams.. |
mozilla/network/tests | Standalone tests |
Netlib
Netlib will first be broken out into static libraries and reintegrated into Mozilla to show compatibility. The libraries will then be individually put behind new interface API's on branches and then landed back on the Mozilla trunk in short intervals. The end result should be a restructured code base with far fewer dependencies. A remote upgrade capability with interface based DLL's, and the ability to do third party plugin protocols and stream converters.
Layout
After the standalone netlib implementation is up and working, a set
of APIs will be defined to allow the NGLayout layout engine to plug into
the current Mozilla code base. After a certain degree of stability
and feature richness is achieved, the old layout code will be excised from
the Mozilla code base. This will leave a partially componentized
product with both a modular layout, netlib, and imagelib.
Dependencies |
Layout
- Working standalone Netlib and reintegration into Gromit
- Further completion of DOM
- Event model
- Style model
- W3C Range proposal
- NGLayout running on Mac and UNIX
- Landing of XPCOM on the tip
Roadmap |
Netlib
- Move nsIURL and the nsURL implementation into netlib
- Support HTTP POST requests by supplying an OutputStream on the nsIURL component
- Finish the nsIStreamNotification implementation
- Move mozilla/lib/libnet code into the new mozilla/network hierarchy
- Make the Mozilla client work with the new mozilla/network code
- Break out the core Netlib code into the Netlib engine DLL
- Make NGLayout work with the new Netlib engine DLL
- Start carving up the rest of the mozilla/network code into separate DLLs and libraries
- main set of framework routines and includes
- protocol plugin framework
- tcp helper routines
- network utility function
- protocols
- http
- gopher
- ftp
- abouturls
- file
- dataurls
- mocha
- marimba
- remote (telnet/rlogin)
- mail protocols
- cache
- net converters
- gunzip
- view-source
- save to disk
- C stream functions (declaration, registry, utility functions for older C based netlib streams)
- C++ stream functions
- Thread-safety. We need to finalize the threading model and make the Netlib engine DLL and multithreaded. Probably, the protocol DLLs will need to be multithreaded as well...
- First pass spec of WebWidget API (5/4)
- Bare-bones demo of NGLayout running in Gromit chrome on Windows (5/13)
- Landing IMGLIB branch on the tip (5/15)
- Finish dependencies document (ongoing)
- Prototype of type-in using NGLayout, in conjunction with the Editor group (5/29)
- First pass editor design (6/1)
- contextual menus
- session history
- Keyboard navigation
- Status messages
- Cut,Copy,Paste
- Bookmarks
- HTML Dialogs
- Window management, multiple browser windows
- Preferences, service and UI
- Printing
- JavaScript-Application interaction
- Find text
- Plugins
- Integration into the Mozilla code base
- MAC Build (5/15)
- Unix Verification (5/15)
- Land XPCOM on tip (5/15)