// Produces adds a MIME type to the list of MIME types the APIs can encode responses with. // Produces may also specify the path of the encoding package. // The package must expose a EncoderFactory method that returns an object which implements // goa.EncoderFactory. func Produces(args ...interface{}) { var v *design.APIVersionDefinition if a, ok := apiDefinition(false); ok { v = a.APIVersionDefinition } else if ver, ok := versionDefinition(true); ok { v = ver } if v == nil { return } if def := buildEncodingDefinition(args...); def != nil { v.Produces = append(v.Produces, def) } }