Interface PendingReference
- All Known Implementing Classes:
CollectionPendingReference
,SingularPendingReference
public interface PendingReference
Represents a pending reference.
A pending reference represents a situation when the JSON-LD contains just an object with and @id
, while the
mapped attribute expects a full-blown object. In this case, it is expected that somewhere in the JSON-LD, there is
the object's full serialization and this is only a reference to it.
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Applies the specified referenced object to this pending reference, resolving it.Gets the target type of the pending reference.
-
Method Details
-
apply
Applies the specified referenced object to this pending reference, resolving it.Resolving the reference basically means inserting the referenced object into the place represented by this instance (e.g., field value, collection).
- Parameters:
referencedObject
- The object referenced by this pending reference
-
getTargetType
Gets the target type of the pending reference.If the target type cannot be reliably determined (for instance, because it is a collection), this method should return
Optional.empty()
.- Returns:
- The target type
-