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

Method r6_instance

r/src/extension-impl.cpp:123–136  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

121}
122
123cpp11::environment RExtensionType::r6_instance(
124 std::shared_ptr<arrow::DataType> storage_type,
125 const std::string& serialized_data) const {
126 // This is a version of to_r6<>() that is a more direct route to creating the object.
127 // This is done to avoid circular calls, since to_r6<>() has to go through
128 // ExtensionType$new(), which then calls back to C++ to get r6_class_ to then
129 // return the correct subclass.
130 std::unique_ptr<RExtensionType> cloned = Clone();
131 cpp11::external_pointer<std::shared_ptr<RExtensionType>> xp(
132 new std::shared_ptr<RExtensionType>(cloned.release()));
133
134 cpp11::function r6_class_new(r6_class()["new"]);
135 return r6_class_new(xp);
136}
137
138// [[arrow::export]]
139cpp11::environment ExtensionType__initialize(

Callers 1

Calls 1

releaseMethod · 0.45

Tested by

no test coverage detected