Package org.spdx.v3jsonldstore
Class JsonLDDeserializer
- java.lang.Object
-
- org.spdx.v3jsonldstore.JsonLDDeserializer
-
public class JsonLDDeserializer extends Object
Class to manage deserializing SPDX 3.X JSON-LD- Author:
- Gary O'Neall
-
-
Constructor Summary
Constructors Constructor Description JsonLDDeserializer(org.spdx.storage.IModelStore modelStore)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.spdx.core.TypedValue
deserializeElement(com.fasterxml.jackson.databind.JsonNode elementNode)
Deserialize a single element into the modelStoreList<org.spdx.core.TypedValue>
deserializeGraph(com.fasterxml.jackson.databind.JsonNode graph)
Deserializes the JSON-LD graph into the modelStore
-
-
-
Method Detail
-
deserializeGraph
public List<org.spdx.core.TypedValue> deserializeGraph(com.fasterxml.jackson.databind.JsonNode graph) throws org.spdx.core.InvalidSPDXAnalysisException
Deserializes the JSON-LD graph into the modelStore- Parameters:
graph
- Graph to deserialize- Returns:
- list of non-anonymous typed value Elements found in the graph nodes
- Throws:
org.spdx.core.InvalidSPDXAnalysisException
- on SPDX parsing errors
-
deserializeElement
public org.spdx.core.TypedValue deserializeElement(com.fasterxml.jackson.databind.JsonNode elementNode) throws net.jimblackler.jsonschemafriend.GenerationException, org.spdx.core.InvalidSPDXAnalysisException
Deserialize a single element into the modelStore- Parameters:
elementNode
- element to deserialize- Returns:
- the typedValue of the deserialized object
- Throws:
org.spdx.core.InvalidSPDXAnalysisException
- on invalid SPDX datanet.jimblackler.jsonschemafriend.GenerationException
- on errors with the JSON schemas
-
-