-
Notifications
You must be signed in to change notification settings - Fork 3
Upgrading to Grax v0.4
The argument order of Grax.load/4
and Grax.load!/4
has been changed, since there’s now also a Grax.load/3
variant without a schema module, which will try to automatically determine the correct schema based on the rdf:type
.
So, where previously a call looked like this:
Grax.load(schema_mod, id, graph, opts)
It now must look like this:
Grax.load(graph, id, schema_mod, opts)
With that, the argument order is now the same as on the generated load
functions of Grax schemas, where it already was that way.
You can no longer can pass the contents of the __additional_statements__
field of one Grax schema as the additional statements to another one. E.g. the following no longer works.
Grax.put_additional_statements(example, other.__additional_statements__)
You should instead pass the result of Grax.additional_statements/1
applied to the one:
Grax.put_additional_statements(example, Grax.additional_statements(other))
You no longer can use nil
values on a property with Grax.put_additional_statements/2
to remove statements with this property. You must use the new Grax.delete_additional_predicates/2
function for this now.