GtkCADFree modular CAD/CAM/CAE Software |
HomeRequirementsDesignScreenshotsFAQProject PageSVNBugsLinks |
Design PhilosophyGtkCAD is an attempt to create a complete design environment based on a spiral or evolutionary design methodology. This design method can be best summed as follows.
DatabaseGtkCAD needs to maintain a complete database of all data created during all phases so reports may be written and data shared among designers, engineers, and clients. Each individual will have varying rights to modify and view the data. Multiple users must be anticipated. With these requirements in mind, a SQL database was chosen to store the data. ModulesGtkCAD code is divided into different modules, each one only doing some concrete tasks. Each module has been written as an isolated part (this has two meanings: each module has its own directory in the source tree and besides its relationship with other modules is intended to be minimal, making as few dependencies as possible). GtkCAD modules have a well defined directory structure. The core functions of the program reside in the toplevel directory. All components related to the UI are located in 'UI'. All components that allow the communication of data with the database is in 'DB'. Routines used to test the plug-in is in Testing. Also included are the directories 'Docs' and 'Examples'. Only the needed functions and data of a module have to be accesible to others; this access has to be made via a well defined API. This API can be seen in the sources as a file named "module".h in that module directory. Other modules calling our module will need to include this header file defining these public entry-points and datastructures. Also, all public functions (entrypoints that will be called by GtkCAD) should have names beginning with the name of the module. Same for public datastructures. Internal functions and datastructures can be named as coder wish. Using this design, each module appears to others as an abstract layer and when it needs some service (data or actions) from other (or vice versa, when there is it who have to do that) only a few well defined functions and data should be used. Doing this way we avoid some inherent common problems huge projects always have. |
Contact H. James Parker at developer at parkersailing dot com