MCPcopy Create free account
hub / github.com/WiseLibs/better-sqlite3 / GetRawRowJS

Method GetRawRowJS

src/util/row-builder.cpp:40–53  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

38}
39
40Napi::Value RowBuilder::GetRawRowJS(Napi::Env env, sqlite3_stmt* handle, bool safe_ints) {
41 column_count = sqlite3_column_count(handle);
42 napi_value arg_storage[16];
43 std::vector<napi_value> extra_args;
44 napi_value* args = arg_storage;
45 if (column_count > 16) {
46 extra_args.resize(column_count);
47 args = extra_args.data();
48 }
49 for (int i = 0; i < column_count; ++i) {
50 args[i] = Data::GetValueJS(env, handle, i, safe_ints);
51 }
52 return SafeCall(env, array_factory.Value(), env.Undefined(), column_count, args);
53}

Callers 1

GetRawRowJSFunction · 0.80

Calls 2

GetValueJSFunction · 0.85
SafeCallFunction · 0.85

Tested by

no test coverage detected