MCPcopy Create free account
hub / github.com/apache/arrow / Serialize

Method Serialize

cpp/src/arrow/extension/opaque.cc:48–62  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

46}
47
48std::string OpaqueType::Serialize() const {
49 JsonWriter writer;
50
51 writer.StartObject();
52
53 writer.StringField("type_name", type_name_);
54 writer.StringField("vendor_name", vendor_name_);
55
56 writer.EndObject();
57
58 Result<std::string_view> json = writer.GetString();
59 // can only fail in OutOfMemory scenarios
60 ARROW_CHECK_OK(json.status());
61 return std::string(*json);
62}
63
64Result<std::shared_ptr<DataType>> OpaqueType::Deserialize(
65 std::shared_ptr<DataType> storage_type, const std::string& serialized_data) const {

Callers

nothing calls this directly

Calls 5

StringFieldMethod · 0.80
StartObjectMethod · 0.45
EndObjectMethod · 0.45
GetStringMethod · 0.45
statusMethod · 0.45

Tested by

no test coverage detected