[JAVA-3923] Add PojoCodec support for Kotlin data classes Created: 08/Jan/21  Updated: 10/Jul/23  Resolved: 10/Jul/23

Status: Closed
Project: Java Driver
Component/s: Kotlin, POJO
Affects Version/s: None
Fix Version/s: None

Type: Improvement Priority: Major - P3
Reporter: Ross Lawley Assignee: Unassigned
Resolution: Duplicate Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Duplicate
duplicates JAVA-3915 Unable to map Kotlin data class with ... Closed
Related
is related to JAVA-3915 Unable to map Kotlin data class with ... Closed
Documentation Changes Summary:

1. What would you like to communicate to the user about this feature?
2. Would you like the user to see examples of the syntax and/or executable code and its output?
3. Which versions of the driver/connector does this apply to?


 Description   

Add support and tests of the PojoCodec using Kotlin data classes.

Currently the following fails:

import kotlinx.serialization.Transient
 
data class Restaurant(
        @Transient
        var name: String? = null,
)

As the POJO mapper is trying to map a synthetic property based on the generated method void getName$annotations().



 Comments   
Comment by Ashni Mehta [ 10/Jul/23 ]

Kotlin server-side driver added data class support. This ticket is no longer needed.

Generated at Thu Feb 08 09:00:47 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.