public B addMember(String memberName, ShapeId target, Consumer<MemberShape.Builder> memberUpdater) {
        if (getId() == null) {
            throw new IllegalStateException("An id must be set before setting a member with a target");
        }

        MemberShape.Builder builder = MemberShape.builder().target(target).id(getId().withMember(memberName));

        if (memberUpdater != null) {
            memberUpdater.accept(builder);
        }

        return addMember(builder.build());
    }
Adds a member to the builder.

@param memberName Member name to add.
@param target Target of the member.
@param memberUpdater Consumer that can update the created member shape.
@return Returns the builder.
smithy-model/src/main/java/software/amazon/smithy/model/shapes/NamedMembersShapeBuilder.java