User: jaza Branch: HEAD Date: Sun, 25 Jun 2006 16:00:20 +0000 Modified files: /modules/importexportapi/definitions importexportapi_profile.inc importexportapi_user.inc /modules/importexportapi/engines importexportapi_db_get.inc importexportapi_xml_put.inc /modules/importexportapi importexportapi.module Log message: - Major overhaul of the definition building system. What was once importexportapi_get_def() is now importexportapi_set_def() - a powerful function that can generate the complete definition library, AND modify the definition for any field at any time. The new importexportapi_get_def() is just a wrapper around the new function. - Overhaul of the engine definition system. hook_engines_get() and hook_engines_put() are now merged into hook_engines_get_put(). The 'build' callback has been removed from hook_field_types(), and is now defined per-engine, through hook_engines_get_put(). This means that definitions can now be built specifically for each engine - i.e. the DB engines handle DB-specific attributes such as 'db_table', and the text output engines handle their specific attributes such as 'mapping'. This is much cleaner than the old system, where attributes for all engines were always all defined per-field type. - It is now possible to export multiple types of entities at once. importexportapi_export_entity() is now importexportapi_export_data() - it is able to build the complete definition library, for fields to have at their disposal (for referencing purposes), and to then selectively build specified entities within that library. - Support for alternate key fields. If a field has its 'alt_key_for' attribute defined, then that field will get copied and re-generated alongside other fields that reference its master key. This automatic copying / generation means that the definition doesn't have to define as much - some fields can be 'inferred'. - Started work on the import system. The 'xml' 'get' engine was working before the definitions overhaul, but is probably broken at present. The 'db' 'put' engine is still highly experimental at this stage. The import system itself needs to be updated to work with the new definition and engine system. Links: http://cvs.drupal.org/diff.php?path=contributions/modules/importexportapi/de... http://cvs.drupal.org/diff.php?path=contributions/modules/importexportapi/de... http://cvs.drupal.org/diff.php?path=contributions/modules/importexportapi/en... http://cvs.drupal.org/diff.php?path=contributions/modules/importexportapi/en... http://cvs.drupal.org/diff.php?path=contributions/modules/importexportapi/im...