mconlon17/vivo-pump

Get must respect type assertions

Closed this issue · 2 comments

Type assertions on objects were implemented for update and as a result, far fewer qualifiers were needed (that's a good thing, qualifiers are slow as they require a new query of VIVO). Qualifiers were removed from defs in favor of type assertions (easier to understand as well as being faster).

But get never implemented type assertions. So removing the qualifiers broke the get functionality for examples previously using qualifiers and now coded with type assertions.

Implement type assertions in get -- this is straightforward. If type assertions exist for the object, add a SPARQL pattern to restrict the result to entities with the desired type.

An example of the problem occurs in the education example where multiple entity relationships must be qualified by type assertions. People and Orgs, for example, have the same "participant" relationship to the AwardedDegree.

This works in get. does not work in update. See #161 and #163

Closing. Fixed for get.