Implement java.io.Serializable on the JVM
See original GitHub issueHello,
Please make the Android actual
types implement also java.io.Serializable
(not Kotlin @Serializable
as described in #37).
This will allow us to make the complex types, which depends on kotlinx.datetime.*
types either Serializable
or Parcelable
in Android app.
For instance, java.time.Instant
IS Serializable
, however the actual
Android class kotlinx.datetime.Instant
is NOT.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:1
- Comments:13 (5 by maintainers)
Top Results From Across the Web
Serialization in Java - DigitalOcean
io. Serializable interface. Serializable in java is a marker interface and has no fields or methods to implement.
Read more >Serializable (Java SE 11 & JDK 11 ) - Oracle Help Center
Serializability of a class is enabled by the class implementing the java.io.Serializable interface. Warning: Deserialization of untrusted data is inherently ...
Read more >Introduction to Java Serialization | Baeldung
The serialization process is instance-independent; for example, we can serialize objects on one platform and deserialize them on another.
Read more >Serialization and Deserialization in Java with Example
To make a Java object serializable we implement the java.io.Serializable interface. The ObjectOutputStream class contains writeObject() ...
Read more >Why Do We Need Serialization in Java? - CodeJava.net
io.Serializable interface. Serializable is a marker interface (contains no methods) that tell the Java Virtual Machine (JVM) that the objects of ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Not related to android. I want to use kotlinx-datetime in wicket. But all wicket models mandate Serializable interface, otherwise NotSerializableException will be thrown.
What do you think about writing
Serializable
Adapters for our classes in place? We provide compatibletoString
andparse
for everything.An overly cautious example that can be slightly simplified if you know what you’re doing:
(be careful to check out
serialVersionUid
if you plan to change this class)