mirror of
https://github.com/msgpack/msgpack-c
synced 2026-06-08 16:11:40 +00:00
Added object conversion description.
+3
-2
@@ -20,9 +20,9 @@ When you use msgpack::unpack() function without unpack_referenc_func, msgpack::u
|
||||
|
||||

|
||||
|
||||
When you unpack msgpack format data, you get msgpack::object from msgpack::unpacked. Then you get various types values from msgpack::object.
|
||||
When you unpack msgpack format data, you get msgpack::object from msgpack::unpacked. Then you get various types values from msgpack::object. If you want to convert to custom types from msgpack::object, see [adaptor](v1_1_cpp_adaptor#convert).
|
||||
|
||||
You can create an msgpack::object from a various type value using the following constructor.
|
||||
You can create a msgpack::object from a various type value using the following constructor. If you want to create a msgpack::object from a custom type, see https://github.com/redboltz/msgpack-c/wiki/v1_1_cpp_adaptor#object and https://github.com/redboltz/msgpack-c/wiki/v1_1_cpp_adaptor#object_with_zone
|
||||
|
||||
```C++
|
||||
template <typename T>
|
||||
@@ -36,3 +36,4 @@ msgpack::object obj(msgpack::type::raw_ref(data, size), zone);
|
||||
```
|
||||
|
||||
The data is NOT copied to the zone.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user