toggle menu
KStore
1.0.0-SNAPSHOT
common
switch theme
search in API
kstore-file
/
io.github.xxfast.kstore.file.extensions
/
VersionedCodec
Versioned
Codec
class
VersionedCodec
<
T
:
@
Serializable
Any
>
(
file
:
Path
,
version
:
Int
=
0
,
json
:
Json
,
serializer
:
KSerializer
<
T
>
,
migration
:
Migration
<
T
>
,
versionPath
:
Path
=
Path("$file.version")
)
:
Codec
<
T
>
Members
Constructors
Versioned
Codec
Link copied to clipboard
constructor
(
file
:
Path
,
version
:
Int
=
0
,
json
:
Json
,
serializer
:
KSerializer
<
T
>
,
migration
:
Migration
<
T
>
,
versionPath
:
Path
=
Path("$file.version")
)
Functions
decode
Link copied to clipboard
open
suspend override
fun
decode
(
)
:
T
?
encode
Link copied to clipboard
open
suspend override
fun
encode
(
value
:
T
?
)