Kotlin query collection format (#4248)

* Fixes incorrect query header collection constants

The OpenApi codegen converts OpenApi v2 documents into an OpenApi v3
representation. The query parameter collection formats are squeezed
into different values from the raw OpenApi 2 collection format values.
For example: csv -> space
See: DefaultCodegen#getCollectionFormat

* Updates kotlin samples
This commit is contained in:
Andrew Emery 2019-10-30 01:55:04 +11:00 committed by William Cheng
parent c8465c40ff
commit a2b37d67c0
9 changed files with 18 additions and 18 deletions

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
{{#nonPublicApi}}internal {{/nonPublicApi}}fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
internal fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}

View File

@ -5,8 +5,8 @@ typealias MultiValueMap = MutableMap<String,List<String>>
fun collectionDelimiter(collectionFormat: String) = when(collectionFormat) {
"csv" -> ","
"tsv" -> "\t"
"pipes" -> "|"
"ssv" -> " "
"pipe" -> "|"
"space" -> " "
else -> ""
}