RDF.default_prefixes

You're seeing just the function default_prefixes, go back to RDF module for more information.

A user-defined RDF.PrefixMap of prefixes to IRI namespaces.

This prefix map will be used implicitly wherever a prefix map is expected, but not provided. For example, when you don't pass a prefix map to the Turtle serializer, this prefix map will be used.

By default the standard_prefixes/0 are part of this prefix map, but you can define additional default prefixes via the default_prefixes compile-time configuration.

For example:

config :rdf,
  default_prefixes: %{
    ex: "http://example.com/"
  }

You can also set :default_prefixes to a module-function tuple {mod, fun} with a function which should be called to determine the default prefixes.

If you don't want the standard_prefixes/0 to be part of the default prefixes, or you want to map the standard prefixes to different namespaces (strongly discouraged!), you can set the use_standard_prefixes compile-time configuration flag to false.

config :rdf,
  use_standard_prefixes: false
Link to this function

default_prefixes(prefix_mappings)

View Source

Returns the default_prefixes/0 with additional prefix mappings.

The prefix_mappings can be given in any format accepted by RDF.PrefixMap.new/1.