Areas | (De)serialization, RPC |
Good if student knows | Tcl, C |
Priority | Medium to Low |
Difficulty | Medium to High |
Benefits to the student | Learning about data serialization, the challenges therein. |
Benefits to Tcl | Enhanced ability to exchange data with other languages |
Mentor | AK, others |
Related Projects & Ideas | GSoC Idea: Tcl Binding to Protocol Buffers GSoC Idea: Tcl Binding to MessagePack GSoC Idea: Updated Tcl bindings for ZeroMQ Tcl YAML |
We currently have three possibilities of handling the (de)serialization of Tcl data structures to other formats. The main constraint in the design is that most (all?) (de)serialization formats around are (strongly) typed, whereas Tcl's basic data structures are not.
The main ways of dealing with this impedance mismatch are:
Each of these methods has their own advantages and disadvantages.
Examples of both (1) and (2) can be found in Tcl YAML , with (1) using separate type description data structures.
The pair of json and json::write packages of Tcllib are another example of (1), using constructor commands on the outbound side.
Regarding approach (3) I am not aware of existing examples.
This is what I am interested in here, with this idea. If that is a feasible approach, and if yes, what are its (dis)advantages ?