You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have a library that exposes the interface Destination and an API accepting this Destination - I need the library to be able to process all destinations with KotlinX.Serialization.
I have a user-land app that defines multiple destinations and joins them via a sealed interface.
packagelibraryinterfaceDestinationpackageapp
@Serializable
sealedinterfaceAppDestination : Destination {
@Serializable
object One : AppDestination
@Serializable
object Two : AppDestination
}
To be able to pass e.g. AppDestination.One to API accepting Destination, I must explicitly wire them together:
I have a library that exposes the interface
Destination
and an API accepting thisDestination
- I need the library to be able to process all destinations with KotlinX.Serialization.I have a user-land app that defines multiple destinations and joins them via a sealed interface.
To be able to pass e.g.
AppDestination.One
to API acceptingDestination
, I must explicitly wire them together:I'd like to be able to utilize the sealed interface and just call the subclass for
AppDestination
Use case: https://github.com/kiwicom/navigation-compose-typed
The text was updated successfully, but these errors were encountered: