Returns the mapping for attributes of a given entity type/bundle pair.
$type: An entity type.
$bundle: (optional) A bundle name.
The mapping corresponding to the requested entity type/bundle pair or an empty array.
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'];
}
else {
return _rdf_get_default_mapping($type);
}
}