private List<ValidationEvent> validateAgainstChildren(ResourceShape resource, Model model) {
        List<ValidationEvent> events = new ArrayList<>();
        for (ShapeId childResourceId : resource.getResources()) {
            ResourceShape childResource = model.expectShape(childResourceId, ResourceShape.class);
            checkForMissing(childResource, resource).ifPresent(e -> events.add(e));
            checkForMismatches(childResource, resource).ifPresent(e -> events.add(e));
        }
        return events;
    }
Validates that the resource identifiers of children of a resource contain
all of the identifiers as their parents.
smithy-model/src/main/java/software/amazon/smithy/model/validation/validators/ResourceIdentifierValidator.java