mirror of
https://github.com/OpenAPITools/openapi-generator.git
synced 2025-12-03 08:46:55 +00:00
[Kotlin] Introduce support for Kotlin Explicit API Mode for Kotlin-Client generator (resolve #16506) (#19999)
* [Kotlin] Properly document nonPublicApi CLI option * [Kotlin] Respect parameter name of parent KSerializer to avoid miss-behavior * [Kotlin] Introduce support for Kotlin Explicit API Mode for Kotlin-Client generator (resolves #16506)
This commit is contained in:
@@ -101,7 +101,7 @@ class ApiClient(
|
||||
|
||||
companion object {
|
||||
@JvmStatic
|
||||
protected val baseUrlKey = "org.openapitools.client.baseUrl"
|
||||
protected val baseUrlKey: String = "org.openapitools.client.baseUrl"
|
||||
|
||||
@JvmStatic
|
||||
val defaultBasePath: String by lazy {
|
||||
|
||||
@@ -6,7 +6,7 @@ import java.net.URI
|
||||
|
||||
class URIAdapter {
|
||||
@ToJson
|
||||
fun toJson(uri: URI) = uri.toString()
|
||||
fun toJson(uri: URI): String = uri.toString()
|
||||
|
||||
@FromJson
|
||||
fun fromJson(s: String): URI = URI.create(s)
|
||||
|
||||
@@ -6,7 +6,7 @@ import java.util.UUID
|
||||
|
||||
class UUIDAdapter {
|
||||
@ToJson
|
||||
fun toJson(uuid: UUID) = uuid.toString()
|
||||
fun toJson(uuid: UUID): String = uuid.toString()
|
||||
|
||||
@FromJson
|
||||
fun fromJson(s: String): UUID = UUID.fromString(s)
|
||||
|
||||
Reference in New Issue
Block a user