private void writeShapeMembers(Collection<MemberShape> members) {
            if (members.isEmpty()) {
                // When there are no members to write, put "{}" on the same line.
                codeWriter.writeInline("{}").write("");
            } else {
                codeWriter.openBlock("{", "}", () -> {
                    for (MemberShape member : members) {
                        serializeTraits(member.getAllTraits(), TraitFeature.MEMBER);
                        String assignment = "";
                        if (member.hasTrait(DefaultTrait.ID)) {
                            assignment = " = " + Node.printJson(member.expectTrait(DefaultTrait.class).toNode());
                        }
                        codeWriter.write("$L: $I$L", member.getMemberName(), member.getTarget(), assignment);
                    }
                });
            }
        }
Serializes shapes in the IDL format.
smithy-model/src/main/java/software/amazon/smithy/model/shapes/SmithyIdlModelSerializer.java