diff options
author | Dries Buytaert <dries@buytaert.net> | 2009-10-19 18:28:16 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2009-10-19 18:28:16 +0000 |
commit | 24669bfb50d643330cd50cbeea21d19d51107a36 (patch) | |
tree | 93eca4ca9d1a4b409b6ee4aac75362080136a5a4 /modules/rdf/rdf.install | |
parent | 0b750209b6ead13c836852eb96bc6cc8f14de51f (diff) | |
download | brdo-24669bfb50d643330cd50cbeea21d19d51107a36.tar.gz brdo-24669bfb50d643330cd50cbeea21d19d51107a36.tar.bz2 |
- Patch #493030 by scor, Stefan Freudenberg, pwolanin, fago, Benjamin Melançon, kriskras, dmitrig01, sun: added RDFa support to Drupal core. Oh my, oh my.
Diffstat (limited to 'modules/rdf/rdf.install')
-rw-r--r-- | modules/rdf/rdf.install | 50 |
1 files changed, 50 insertions, 0 deletions
diff --git a/modules/rdf/rdf.install b/modules/rdf/rdf.install new file mode 100644 index 000000000..0467842a6 --- /dev/null +++ b/modules/rdf/rdf.install @@ -0,0 +1,50 @@ +<?php +// $Id$ + +/** + * @file + * Install, update and uninstall functions for the rdf module. + */ + +/** + * Implements hook_schema(). + */ +function rdf_schema() { + $schema['rdf_mapping'] = array( + 'description' => 'Stores custom RDF mappings for user defined content types or overriden module-defined mappings', + 'fields' => array( + 'type' => array( + 'type' => 'varchar', + 'length' => 128, + 'not null' => TRUE, + 'description' => 'The name of the entity type a mapping applies to (node, user, comment, etc.).', + ), + 'bundle' => array( + 'type' => 'varchar', + 'length' => 128, + 'not null' => TRUE, + 'description' => 'The name of the bundle a mapping applies to.', + ), + 'mapping' => array( + 'description' => 'The serialized mapping of the bundle type and fields to RDF terms.', + 'type' => 'text', + 'not null' => FALSE, + 'size' => 'big', + 'serialize' => TRUE, + ), + ), + 'primary key' => array('type', 'bundle'), + ); + + return $schema; +} + +/** + * Implements hook_install(). + */ +function rdf_install() { + // The installer does not trigger hook_modules_installed() so it needs to + // triggered programmatically on the modules which defined RDF mappings. + $modules = module_implements('rdf_mapping'); + rdf_modules_installed($modules); +} |