code: func GenerateMediaTypeDefinition(api *design.APIDefinition, mt *design.MediaTypeDefinition, view string) {
  	if _, ok := Definitions[mt.TypeName]; ok {
  		return
  	}
  	s := NewJSONSchema()
  	s.Title = fmt.Sprintf("Mediatype identifier: %s", mt.Identifier)
  	Definitions[mt.TypeName] = s
  	buildMediaTypeSchema(api, mt, view, s)
  }
docs: // GenerateMediaTypeDefinition produces the JSON schema corresponding to the given media type and
  // given view.