MCPcopy Create free account
hub / github.com/PlotJuggler/PlotJuggler / invoke

Method invoke

pj_datastore/src/plugin_data_host.cpp:1598–1608  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

1596 PluginFetchCtx& operator=(PluginFetchCtx&&) = delete;
1597
1598 [[nodiscard]] std::vector<uint8_t> invoke() const {
1599 if (fetch_fn_ == nullptr) {
1600 return {};
1601 }
1602 const uint8_t* data = nullptr;
1603 uint64_t size = 0; // matches PJ_lazy_fetch_fn_t out_size (uint64_t*)
1604 if (!fetch_fn_(ctx_, &data, &size) || data == nullptr) {
1605 return {};
1606 }
1607 return std::vector<uint8_t>(data, data + size);
1608 }
1609
1610 private:
1611 PJ_lazy_fetch_fn_t fetch_fn_;

Callers 2

sourceObjectPushLazyFunction · 0.80
parserObjectPushLazyFunction · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected