Attempting to read a JSON ontology with Jackson like so:
ObjectMapper objectMapper = new ObjectMapper();
GraphDocument graphDocument = objectMapper.readValue(Files.newInputStream(Paths.get("src/test/resources/hp.json")), GraphDocument.class);
results in:
com.fasterxml.jackson.databind.JsonMappingException: Can not construct instance of org.geneontology.obographs.model.GraphDocument: no suitable constructor found, can not deserialize from Object value (missing default constructor or creator, or perhaps need to add/enable type information?)
at [Source: sun.nio.ch.ChannelInputStream@471a9022; line: 2, column: 3]
This is likely due to model missing '@JsonDeserialize(builder = Node.Builder.class)' annotations.
@cmungall @balhoff @dosumis - I've added what I think are all the missing annotations allowing people to read the json documents back into memory from disk. Do you have any way of testing this is complete?
Attempting to read a JSON ontology with Jackson like so:
results in:
This is likely due to model missing '@JsonDeserialize(builder = Node.Builder.class)' annotations.