#1 2024-12-11 17:31:47

salah eddine frigini
Member
Registered: 2024-10-12
Posts: 7

serialize and deserialize JSON in a cross-platform

Hi, I want to ask: Is there any way to serialize and deserialize JSON in a cross-platform FMX application (e.g., for Android) using mORMot, similar to the RecordSaveJSON() and RecordLoadJSON() functions? I read in the documentation that we can use JSONVariant, but this just converts JSON to a variant. I'm looking for a solution that would allow proper serialization and deserialization of records or objects, as those functions do.

Offline

#2 2024-12-11 17:39:12

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,742
Website

Re: serialize and deserialize JSON in a cross-platform

No FMX support, sorry.

Offline

#3 2024-12-12 07:51:22

salah eddine frigini
Member
Registered: 2024-10-12
Posts: 7

Re: serialize and deserialize JSON in a cross-platform

Even with mormot 1 ?

Offline

#4 2024-12-12 07:58:01

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,742
Website

Re: serialize and deserialize JSON in a cross-platform

You have https://github.com/synopse/mORMot/blob/ … rmJSON.pas which is independent from the main mORMot 1 (or mORMot 2) codebase.
It supports basic serialization of class instances (published properties) but not records.

Offline

Board footer

Powered by FluxBB