From 56bf0107ae25c20d1044356472738e4b28e4151c Mon Sep 17 00:00:00 2001 From: "Claudius \"keldu\" Holeksa" Date: Mon, 20 Oct 2025 10:22:52 +0200 Subject: Added internal access to data --- modules/codec/c++/data.hpp | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) diff --git a/modules/codec/c++/data.hpp b/modules/codec/c++/data.hpp index 013b475..18b7b27 100644 --- a/modules/codec/c++/data.hpp +++ b/modules/codec/c++/data.hpp @@ -760,6 +760,23 @@ class data, encode::Native> { return {dims_}; } + /** + * + */ + data internal_size() const { + return {value_.size()}; + } + + /** + * Available for contiguous encodings + */ + data* internal_data() { + if(value_.size() == 0u){ + return nullptr; + } + return &value_[0u]; + } + private: template uint64_t get_flat_index(const U& i) const { -- cgit v1.2.3