You are here

function _rdfx_serialization_formats in RDF Extensions 7.2

Lists the RDF serializations format which will be integrated with RestWS.

Does not implement hook_restws_format_info() because we need to override the RDF serialization format to use our own ARC2 based serializer.

1 call to _rdfx_serialization_formats()
rdfx_restws_format_info_alter in ./rdfx.module
Implements hook_restws_format_info_alter().

File

./rdfx.module, line 323
Extends the RDF API of Drupal core to support more RDF seralizations formats other RDF capabilities.

Code

function _rdfx_serialization_formats() {
  $result['rdf'] = array(
    'label' => t('RDF/XML'),
    'class' => 'RDFxRestWSFormatRDFXML',
    'mime type' => 'application/rdf+xml',
  );
  $result['ttl'] = array(
    'label' => t('Turtle'),
    'class' => 'RDFxRestWSFormatTurtle',
    'mime type' => 'application/x-turtle',
  );
  $result['nt'] = array(
    'label' => t('NTriples'),
    'class' => 'RDFxRestWSFormatNTriples',
    'mime type' => 'text/plain',
  );
  $result['rdfjson'] = array(
    'label' => t('RDFJSON'),
    'class' => 'RDFxRestWSFormatRDFJSON',
    'mime type' => 'application/json',
  );
  return $result;
}