private Map<String, Set<String>> computePotentialStructureBindings(Shape structure) {
        Map<String, Set<String>> bindings = new HashMap<>();
        // Ensure no two members are bound to the same identifier.
        for (MemberShape member : structure.members()) {
            String bindingName = member.getTrait(ResourceIdentifierTrait.class)
                    .map(ResourceIdentifierTrait::getValue)
                    .orElseGet(member::getMemberName);
            bindings.computeIfAbsent(bindingName, k -> new HashSet<>()).add(member.getMemberName());
        }
        return bindings;
    }
Validates that operations bound to resource shapes have identifier
bindings for all the identifiers of the parent of the binding resource,
that operations bound to a resource with the {@code collection}
trait are bound using a collection binding, and operations bound with
no {@code collection} trait are bound using an instance binding.
smithy-model/src/main/java/software/amazon/smithy/model/validation/validators/ResourceIdentifierBindingValidator.java