antirez / antirez/lua-cmsgpack

Extension type support

Offen
#49 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
C
Sterne
383
Forks
122
PR-Merge-Kennzahlen
Keine gemergten PRs in 30 T.

Beschreibung

Any chance of adding hooks to support [extension types](https://github.com/msgpack/msgpack/blob/master/spec.md#types-extension-type)? This would basically require an API where callers could specify two callback functions one for encoding and one for decoding. Then `mp_encode_lua_type` and `mp_decode_to_lua_type` would call these functions to produce the actual values to be used when serializing.

Examples of two different ways this can be done for msgpack-python are below

https://pypi.python.org/pypi/msgpack-python#packing-unpacking-of-custom-data-type
https://pypi.python.org/pypi/msgpack-python#extended-types

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.