Limb contains the following directories in its root directory:
+-LIMB_DIR | +-core (here all Limb classes are stored except test cases) | +-design (site appearance: images, templates, css-files etc) | +-var (PHP compiled templates, media files, log | and cache file are stored here) | +-tests (Simpletest cases)
Project file structure should be similar to Limb. This is required by file path resolving rules.
Now we can examine the directory structure in more detail.
+-LIMB_DIR/core | +-actions (all classes that implement site functionality | are stored here. The action classes for site_objects | are usually kept in directories named specifically to | simplify browsing, e.g. create_article_action, edit_article_action | and delete_article_action are good candidates to be stored in the | Limb/core/actions/article directory, this is not mandatory | yet it helps to grow familiar with Limb) | +-controllers (site objects controllers are placed here) | +-datasource (fetching helper classes can be found here. | Limb templates are active and their activity mostly | implemented by datasources) | +-db_tables (db_tables are classes representing specific | tables in the data base. These classes have methods for | type-casting, fetching/creating/editing/deleting rows. | They're also useful for cascade deleting since some db | drivers don't support this feature(e.g. MySQL). | In the nearest future we are planning to use db tables to | create specific db schema automatically) | +-filters (intercepting filters are here). | +-lib (this a Limb utility library) | +-locale (ini-files for locale configurations can be found here) | +-model (Limb keeps model classes mostly here. However one can | find also audit, statistics, search, response related | stuff here too(subject to be placed somewhere else). | +-request (request and response classes. action->perform() is | responsible to return some response) | +-settings (settings ini-files are kept here) | +-strings (ini-files with localized strings) | +-template (WACT template mechanism with Limb specific tags | and components) | +-tree (classes to deal with hierarchic structures)
LIMB_DIR/core/model directory
+-LIMB_DIR/core/model | +-search (search functionality classes) | +-shop (a simple yet robust implementation of the shopping | cart) | +-site_objects (site_objects classes) | +-stats (statistics and user audit related classes are kept here. You can also find here stats and audit report classes)
LIMB_DIR/core/template directory
+-LIMB_DIR/core/templates | +-compiler (compiler classes) | +-components (runtime components classes) | +-fileschemes (file name resolving classes) | +-tags (tags files) | +-actions (tags to display JIP-actions) | +-cart (helper tags for shopping cart) | +-core (some core WACT original tags and a lot | of Limb specific ones(probably some of | these should be moved to somewhere else) | +-datasource (datasource tag) | +-dev (tags to view templates sources) | +-fetch (template's fetching tags) | +-form (tags to work with forms. | Includes selectors, buttons, inputs, etc) | +-grid (tags to output tabular data, | substitute for WACT list tags) | +-hint (tags to display small popups with legend) | +-locale (data l10n tags) | +-metadata (meta specific tags) | +-pager (tag for tabular data paginating) | +-phpbb (some helper tags to use Limb integrated version of phpbb) | +-poll (poll tags) | +-print (outputs link to print version of object | if it supports print_version action) | +-status (document flow tags) | +-user (some helper tags to render user specific attributes, like login, name, etc)
Обсуждение