13#ifndef ROOT_RNTupleUtils
14#define ROOT_RNTupleUtils
37 const static std::shared_ptr<T> fgRawPtrCtrlBlock;
38 return std::shared_ptr<T>(fgRawPtrCtrlBlock, rawPtr);
48 return std::unique_ptr<T[]>(
new T[
size]);
58 std::vector<std::unique_ptr<std::string>>
fStrings;
61 static bool Less(
const std::unique_ptr<std::string> &
a,
const std::string_view &
b) {
return *
a <
b; }
73 const std::string *
Intern(std::string_view str);
82 virtual void AddTask(
const std::function<
void(
void)> &taskFunc) = 0;
size_t size(const MatrixT &matrix)
retrieve the size of a square matrix
The interface of a task scheduler to schedule page (de)compression tasks.
virtual void Wait()=0
Blocks until all scheduled tasks finished.
virtual ~RNTupleTaskScheduler()=default
virtual void AddTask(const std::function< void(void)> &taskFunc)=0
Take a callable that represents a task.
Used for string interning of repeated type names, field names, etc.
const std::string * Intern(std::string_view str)
Searches for str in the pool.
RStringPool(RStringPool &&other)=default
static bool Less(const std::unique_ptr< std::string > &a, const std::string_view &b)
RStringPool & operator=(RStringPool &&other)=default
RStringPool(const RStringPool &other)=delete
RStringPool & operator=(const RStringPool &other)=delete
std::vector< std::unique_ptr< std::string > > fStrings
A log configuration for a channel, e.g.
The class is used as a return type for operations that can fail; wraps a value of type T or an RError...
RResult< void > EnsureValidNameForRNTuple(std::string_view name, std::string_view where)
Check whether a given string is a valid name according to the RNTuple specification.
ROOT::RLogChannel & NTupleLog()
Log channel for RNTuple diagnostics.
std::unique_ptr< T[]> MakeUninitArray(std::size_t size)
Make an array of default-initialized elements.
auto MakeAliasedSharedPtr(T *rawPtr)