function rdf_mapping_load
rdf_mapping_load($type, $bundle = RDF_DEFAULT_BUNDLE)
Returns the mapping for attributes of a given entity type/bundle pair.
Parameters
$type: An entity type.
$bundle: (optional) A bundle name.
Return value
The mapping corresponding to the requested entity type/bundle pair or an empty array.
Related topics
File
- modules/rdf/rdf.module, line 133
- Enables semantically enriched output for Drupal sites in the form of RDFa.
Code
function rdf_mapping_load($type, $bundle = RDF_DEFAULT_BUNDLE) { // Retrieves the bundle-specific mapping from the entity info. $entity_info = entity_get_info($type); if (!empty($entity_info['bundles'][$bundle]['rdf_mapping'])) { return $entity_info['bundles'][$bundle]['rdf_mapping']; } // If there is no mapping defined for this bundle, we return the default // mapping that is defined for this entity type. else { return _rdf_get_default_mapping($type); } }
© 2001–2016 by the original authors
Licensed under the GNU General Public License, version 2 and later.
Drupal is a registered trademark of Dries Buytaert.
https://api.drupal.org/api/drupal/modules!rdf!rdf.module/function/rdf_mapping_load/7.x