25 : fModel(model), fIndex(index), fPageSink(nullptr), fPageSource(nullptr), fHeadPage(), fNElements(0),
33 if (!fHeadPage.IsNull())
34 fPageSink->ReleasePage(fHeadPage);
35 if (!fCurrentPage.IsNull())
36 fPageSource->ReleasePage(fCurrentPage);
41 switch (pageStorage->
GetType()) {
43 fPageSink =
static_cast<RPageSink*
>(pageStorage);
44 fHandleSink = fPageSink->
AddColumn(fieldId, *
this);
45 fHeadPage = fPageSink->ReservePage(fHandleSink);
48 fPageSource =
static_cast<RPageSource*
>(pageStorage);
49 fHandleSource = fPageSource->
AddColumn(fieldId, *
this);
50 fNElements = fPageSource->GetNElements(fHandleSource);
51 fColumnIdSource = fPageSource->GetColumnId(fHandleSource);
60 if (fHeadPage.GetSize() == 0)
return;
62 fPageSink->CommitPage(fHandleSink, fHeadPage);
63 fHeadPage.Reset(fNElements);
68 fPageSource->ReleasePage(fCurrentPage);
69 fCurrentPage = fPageSource->PopulatePage(fHandleSource, index);
74 fPageSource->ReleasePage(fCurrentPage);
75 fCurrentPage = fPageSource->PopulatePage(fHandleSource, clusterIndex);
void Connect(DescriptorId_t fieldId, RPageStorage *pageStorage)
void MapPage(const NTupleSize_t index)
RColumn(const RColumnModel &model, std::uint32_t index)
Abstract interface to write data into an ntuple.
ColumnHandle_t AddColumn(DescriptorId_t fieldId, const RColumn &column) final
Register a new column.
Abstract interface to read data from an ntuple.
ColumnHandle_t AddColumn(DescriptorId_t fieldId, const RColumn &column) final
Register a new column.
Common functionality of an ntuple storage for both reading and writing.
virtual EPageStorageType GetType()=0
Whether the concrete implementation is a sink or a source.
Addresses a column element or field item relative to a particular cluster, instead of a global NTuple...
Holds the static meta-data of a column in a tree.
std::uint64_t NTupleSize_t
Integer type long enough to hold the maximum number of entries in a column.
constexpr ColumnId_t kInvalidColumnId
std::uint64_t DescriptorId_t
Distriniguishes elements of the same type within a descriptor, e.g. different fields.