code: func goTypeDefObject(obj design.Object, def *design.AttributeDefinition, tabs int, jsonTags, private bool) string {
  	var buffer bytes.Buffer
  	buffer.WriteString("struct {\n")
  	keys := make([]string, len(obj))
  	i := 0
  	for n := range obj {
  		keys[i] = n
  		i++
  	}
  	sort.Strings(keys)
  	for _, name := range keys {
  		WriteTabs(&buffer, tabs+1)
  		field := obj[name]
  		typedef := GoTypeDef(field, tabs+1, jsonTags, private)
  		if (private && field.Type.IsPrimitive() && !def.IsInterface(name)) || field.Type.IsObject() || def.IsPrimitivePointer(name) {
  			typedef = "*" + typedef
  		}
  		fname := GoifyAtt(field, name, true)
  		var tags string
  		if jsonTags {
  			tags = attributeTags(def, field, name, private)
  		}
  		desc := obj[name].Description
  		if desc != "" {
  			desc = strings.Replace(desc, "\n", "\n\t// ", -1)
  			desc = fmt.Sprintf("// %s\n\t", desc)
  		}
  		buffer.WriteString(fmt.Sprintf("%s%s %s%s\n", desc, fname, typedef, tags))
  	}
  	WriteTabs(&buffer, tabs)
  	buffer.WriteString("}")
  	return buffer.String()
  }
docs: // goTypeDefObject returns the Go code that defines a Go struct.