From 939ca7f6d5a534be73507e26f966cf5088434cea Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 13 May 2024 10:38:43 +0200 Subject: [PATCH] Bump exposed from 0.49.0 to 0.50.1 (#334) * Bump exposed from 0.49.0 to 0.50.1 Bumps `exposed` from 0.49.0 to 0.50.1. Updates `org.jetbrains.exposed:exposed-dao` from 0.49.0 to 0.50.1 - [Release notes](https://github.com/JetBrains/Exposed/releases) - [Changelog](https://github.com/JetBrains/Exposed/blob/main/CHANGELOG.md) - [Commits](https://github.com/JetBrains/Exposed/compare/0.49.0...0.50.1) Updates `org.jetbrains.exposed:exposed-jdbc` from 0.49.0 to 0.50.1 - [Release notes](https://github.com/JetBrains/Exposed/releases) - [Changelog](https://github.com/JetBrains/Exposed/blob/main/CHANGELOG.md) - [Commits](https://github.com/JetBrains/Exposed/compare/0.49.0...0.50.1) --- updated-dependencies: - dependency-name: org.jetbrains.exposed:exposed-dao dependency-type: direct:production update-type: version-update:semver-minor - dependency-name: org.jetbrains.exposed:exposed-jdbc dependency-type: direct:production update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Add generic type --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Philip Wedemann <22521688+hfhbd@users.noreply.github.com> --- gradle/libs.versions.toml | 2 +- kotlinx-uuid-exposed/api/kotlinx-uuid-exposed.api | 6 ++++-- .../src/main/kotlin/kotlinx/uuid/exposed/UUIDColumnType.kt | 6 +++--- 3 files changed, 8 insertions(+), 6 deletions(-) diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index 3f3dd3d..8c46a82 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -1,7 +1,7 @@ [versions] kotlin = "2.0.0-RC3" serialization = "1.6.3" -exposed = "0.49.0" +exposed = "0.50.1" [libraries] serialization-core = { module = "org.jetbrains.kotlinx:kotlinx-serialization-core", version.ref = "serialization" } diff --git a/kotlinx-uuid-exposed/api/kotlinx-uuid-exposed.api b/kotlinx-uuid-exposed/api/kotlinx-uuid-exposed.api index 7e7514c..80ae5ee 100644 --- a/kotlinx-uuid-exposed/api/kotlinx-uuid-exposed.api +++ b/kotlinx-uuid-exposed/api/kotlinx-uuid-exposed.api @@ -23,8 +23,10 @@ public class kotlinx/uuid/exposed/KotlinxUUIDTable : org/jetbrains/exposed/dao/i public final class kotlinx/uuid/exposed/UUIDColumnType : org/jetbrains/exposed/sql/ColumnType { public fun ()V - public fun nonNullValueToString (Ljava/lang/Object;)Ljava/lang/String; - public fun notNullValueToDB (Ljava/lang/Object;)Ljava/lang/Object; + public synthetic fun nonNullValueToString (Ljava/lang/Object;)Ljava/lang/String; + public fun nonNullValueToString (Lkotlinx/uuid/UUID;)Ljava/lang/String; + public synthetic fun notNullValueToDB (Ljava/lang/Object;)Ljava/lang/Object; + public fun notNullValueToDB (Lkotlinx/uuid/UUID;)Ljava/lang/Object; public fun sqlType ()Ljava/lang/String; public synthetic fun valueFromDB (Ljava/lang/Object;)Ljava/lang/Object; public fun valueFromDB (Ljava/lang/Object;)Lkotlinx/uuid/UUID; diff --git a/kotlinx-uuid-exposed/src/main/kotlin/kotlinx/uuid/exposed/UUIDColumnType.kt b/kotlinx-uuid-exposed/src/main/kotlin/kotlinx/uuid/exposed/UUIDColumnType.kt index 83eefa9..adff91d 100644 --- a/kotlinx-uuid-exposed/src/main/kotlin/kotlinx/uuid/exposed/UUIDColumnType.kt +++ b/kotlinx-uuid-exposed/src/main/kotlin/kotlinx/uuid/exposed/UUIDColumnType.kt @@ -13,7 +13,7 @@ import java.nio.* * A [UUID] column type for registering in exposed tables. * @see kotlinxUUID to see how it is used */ -public class UUIDColumnType : ColumnType() { +public class UUIDColumnType : ColumnType() { override fun sqlType(): String = currentDialect.dataTypeProvider.uuidType() override fun valueFromDB(value: Any): UUID = when { @@ -25,9 +25,9 @@ public class UUIDColumnType : ColumnType() { else -> error("Unexpected value of type UUID: $value of ${value::class.qualifiedName}") } - override fun notNullValueToDB(value: Any): Any = currentDialect.dataTypeProvider.uuidToDB(valueToUUID(value)) + override fun notNullValueToDB(value: UUID): Any = currentDialect.dataTypeProvider.uuidToDB(valueToUUID(value)) - override fun nonNullValueToString(value: Any): String = "'${valueToUUID(value)}'" + override fun nonNullValueToString(value: UUID): String = "'${valueToUUID(value)}'" internal fun valueToUUID(value: Any): java.util.UUID = when (value) { is java.util.UUID -> value