Add ability to customize CollectionFormat in swagger output.
I have query string parameter that parses multiple parameters like so: "foo=bar&foo=baz", but swagger's docs see it as "foo=bar%2Cbaz". I believe this is because the CollectionFormat defaults to 'None' in our generator which translates to 'csv' which is NOT what I need.
We need a way, probably on the QueryParser or param to specify the collection format we want to use.
Here are the valid values from swagger's documentation:
csv - comma separated values foo,bar. ssv - space separated values foo bar. tsv - tab separated values foo\tbar. pipes - pipe separated values foo|bar. multi - corresponds to multiple parameter instances instead of multiple values for a single instance foo=bar&foo=baz. This is valid only for parameters in "query" or "formData".
Default value is csv.
Just come across this issue which is exactly what I need for an API I'm working on. We specify multiple values using the multi style, but the generated swagger omits the collectionFormat property since it's never set in the QueryParameter model class.
Would be awesome to be able to specify the collection format on a multi-value query parameter.