Class AccJsonObject
java.lang.Object
org.aksw.jenax.io.json.accumulator.AccJsonBase
org.aksw.jenax.io.json.accumulator.AccJsonObjectLikeBase
org.aksw.jenax.io.json.accumulator.AccJsonObject
- All Implemented Interfaces:
AccJson,AccJsonNode,AccJsonObjectLike
-
Field Summary
Fields inherited from class org.aksw.jenax.io.json.accumulator.AccJsonObjectLikeBase
currentFieldAcc, currentFieldIndex, edgeAccs, fieldIdToIndexFields inherited from class org.aksw.jenax.io.json.accumulator.AccJsonBase
currentSourceNode, hasBegun, oldSourceNode, parent, skipOutput, value -
Constructor Summary
ConstructorsModifierConstructorDescriptionShould not be used directly; useAggJsonEdgeas the builderprotectedAccJsonObject(Map<org.apache.jena.graph.Node, Integer> fieldIdToIndex, AccJsonEdge[] edgeAccs) -
Method Summary
Modifier and TypeMethodDescriptionvoidbegin(org.apache.jena.graph.Node source, AccContextRdf context, boolean skipOutput) Start accumulation based on a given node in the underlying graph.voidend(AccContextRdf context) End the accumulator's current nodestatic AccJsonObjectof(Map<org.apache.jena.graph.Node, Integer> fieldIdToIndex, AccJsonEdge[] edgeAccs) Create a new instance and set it as the parent on all the property accumulatorstoString()transition(org.apache.jena.graph.Triple input, AccContextRdf context) Process an edge.Methods inherited from class org.aksw.jenax.io.json.accumulator.AccJsonObjectLikeBase
acceptContribution, addEdge, getPathMethods inherited from class org.aksw.jenax.io.json.accumulator.AccJsonBase
ensureBegun, getInternalValue, getParent, getValue, hasBegun, setParent
-
Constructor Details
-
AccJsonObject
public AccJsonObject()Should not be used directly; useAggJsonEdgeas the builder -
AccJsonObject
protected AccJsonObject(Map<org.apache.jena.graph.Node, Integer> fieldIdToIndex, AccJsonEdge[] edgeAccs)
-
-
Method Details
-
of
public static AccJsonObject of(Map<org.apache.jena.graph.Node, Integer> fieldIdToIndex, AccJsonEdge[] edgeAccs) Create a new instance and set it as the parent on all the property accumulators -
begin
public void begin(org.apache.jena.graph.Node source, AccContextRdf context, boolean skipOutput) throws IOException Description copied from interface:AccJsonStart accumulation based on a given node in the underlying graph. Calls cannot be nested.- Specified by:
beginin interfaceAccJson- Overrides:
beginin classAccJsonBase- Parameters:
source- The source node to which the next incoming edge(s) will connect tocontext- The context which holds the JSON serializersskipOutput- When output should be disabled (used e.g. to skip over lists of items where just one was expected)- Throws:
IOException
-
transition
public AccJson transition(org.apache.jena.graph.Triple input, AccContextRdf context) throws IOException Description copied from interface:AccJsonProcess an edge. Based on the given edge, this accumulator attempts to transition to another AccJson instance and return it. If there is no valid transition then this method returns null.- Throws:
IOException
-
end
Description copied from interface:AccJsonEnd the accumulator's current node- Specified by:
endin interfaceAccJson- Overrides:
endin classAccJsonBase- Throws:
IOException
-
toString
-