예제 #1
0
 private ModelReference<?> mapSubject(ModelReference<?> subject, ModelPath targetPath) {
   if (subject.getPath() == null) {
     return subject.inScope(targetPath);
   } else {
     return subject.withPath(targetPath.descendant(subject.getPath()));
   }
 }
예제 #2
0
 private void mapInputs(List<ModelReference<?>> inputs, ModelPath targetPath) {
   for (int i = 0; i < inputs.size(); i++) {
     ModelReference<?> input = inputs.get(i);
     if (input.getPath() != null) {
       inputs.set(i, input.withPath(targetPath.descendant(input.getPath())));
     } else {
       inputs.set(i, input.inScope(ModelPath.ROOT));
     }
   }
 }