public RdfMappingInterface::setBundleMapping(array $mapping)
Sets the mapping config for the bundle-level data.
This only sets bundle-level mappings, such as the RDF type. Mappings for a bundle's fields should be handled with setFieldMapping.
Example usage: -Map the 'article' bundle to 'sioc:Post'.
1 2 3 4 5 | rdf_get_mapping( 'node' , 'article' ) ->setBundleMapping( array ( 'types' => array ( 'sioc:Post' ), )) ->save(); |
Parameters
array $mapping: The bundle mapping.
Return value
\Drupal\rdf\Entity\RdfMapping The RdfMapping object.
File
- core/modules/rdf/src/RdfMappingInterface.php, line 60
Class
- RdfMappingInterface
- Provides an interface defining an RDF mapping entity.
Namespace
Drupal\rdf
Code
1 | public function setBundleMapping( array $mapping ); |
Please login to continue.