@@ -220,7 +220,7 @@ private SerializedClassifierInstance serializeAnnotationInstance(
220
220
Objects .requireNonNull (annotationInstance , "AnnotationInstance should not be null" );
221
221
SerializedAnnotationInstance serializedClassifierInstance = new SerializedAnnotationInstance ();
222
222
serializedClassifierInstance .setID (annotationInstance .getID ());
223
- serializedClassifierInstance .setAnnotated (annotationInstance .getAnnotated ().getID ());
223
+ serializedClassifierInstance .setParentNodeID (annotationInstance .getParent ().getID ());
224
224
serializedClassifierInstance .setClassifier (
225
225
MetaPointer .from (annotationInstance .getAnnotationDefinition ()));
226
226
serializeProperties (annotationInstance , serializedClassifierInstance );
@@ -396,12 +396,12 @@ private List<SerializedClassifierInstance> sortLeavesFirst(
396
396
} else if (n instanceof SerializedAnnotationInstance ) {
397
397
SerializedAnnotationInstance serializedAnnotationInstance =
398
398
(SerializedAnnotationInstance ) n ;
399
- if (serializedAnnotationInstance .getAnnotated () == null
399
+ if (serializedAnnotationInstance .getParentNodeID () == null
400
400
|| sortedList .stream ()
401
401
.anyMatch (
402
402
sn ->
403
403
Objects .equals (
404
- sn .getID (), serializedAnnotationInstance .getAnnotated ()))) {
404
+ sn .getID (), serializedAnnotationInstance .getParentNodeID ()))) {
405
405
sortedList .add (n );
406
406
nodesToSort .remove (i );
407
407
i --;
@@ -478,13 +478,13 @@ private List<ClassifierInstance<?>> unserializeClassifierInstances(
478
478
+ n );
479
479
}
480
480
Node annotatedNode =
481
- (Node ) unserializedByID .get (serializedAnnotationInstance .getAnnotated ());
481
+ (Node ) unserializedByID .get (serializedAnnotationInstance .getParentNodeID ());
482
482
AnnotationInstance annotationInstance = (AnnotationInstance ) classifierInstance ;
483
483
if (annotatedNode != null ) {
484
484
annotatedNode .addAnnotation (annotationInstance );
485
485
} else {
486
486
throw new IllegalStateException (
487
- "Cannot resolved annotated node " + annotationInstance .getAnnotated ());
487
+ "Cannot resolved annotated node " + annotationInstance .getParent ());
488
488
}
489
489
}
490
490
});
0 commit comments