dump_rdf

dump_rdf(key: str, *subkeys: str, name: str, obj: rdflib.Graph, format: str = 'turtle', serialize_kwargs: Mapping[str, Any] | None = None) None[source]

Dump an RDF graph to a file with rdflib.

Parameters:
  • key – The name of the module. No funny characters. The envvar <key>_HOME where key is uppercased is checked first before using the default home directory.

  • subkeys – A sequence of additional strings to join. If none are given, returns the directory for this module.

  • name – The name of the file to open

  • obj – The object to dump

  • format – The format to dump in

  • serialize_kwargs – Keyword arguments to through to rdflib.Graph.serialize().