ZeroInt
Represents an integer number of type Int that equals zero.
Serialization and deserialization
The serialization and deserialization processes of this type behave like for the Int type.
Here's an example of Kotlin code that encodes and decodes this type using the JavaScript Object Notation (JSON) format from kotlinx.serialization:
val encoded: String = Json.encodeToString(ZeroInt)
assertEquals(expected = "0", actual = encoded)
val decoded: ZeroInt = Json.decodeFromString(encoded)
assertSame(expected = ZeroInt, actual = decoded)Content copied to clipboard
Since
4.0.0
Functions
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Calculates the remainder of truncating division of this integer by the other one.