- All Known Subinterfaces:
ScopeMixin
- All Known Implementing Classes:
DefaultScope
public interface Scope
API for resolving cross-references in serialized object graphs.
-
Method Summary
Modifier and TypeMethodDescriptionvoidreadData(SharedGraphNode node, int id, JsonReader in) Reads object data of the given node and assigns the given ID to this node.resolveOrFail(int id) Looks up the object with the given ID.voidwriteRefOrData(JsonWriter out, SharedGraphNode node) Writes the given graph node to the given writer.
-
Method Details
-
resolveOrFail
Looks up the object with the given ID.- Parameters:
id- The ID of the requested object.- Returns:
- The object with the given ID.
- Throws:
IllegalArgumentException- If there is no object with the requested ID.
-