ServiceLoader.load(ChildEntityDefinition.class, inspectedType.getClassLoader()); for (Field field : ReflectionUtils.fieldsOf(inspectedType)) { childEntityDefinitions.forEach(def -> def.createChildDefinition(field, this).ifPresent(child -> { children.add(child); commandHandlers.addAll(child.commandHandlers());
ServiceLoader.load(ChildEntityDefinition.class, inspectedType.getClassLoader()); for (Field field : ReflectionUtils.fieldsOf(inspectedType)) { childEntityDefinitions.forEach(def -> def.createChildDefinition(field, this).ifPresent(child -> { children.add(child); commandHandlers.addAll(child.commandHandlers());