File tree Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Expand file tree Collapse file tree 2 files changed +10
-0
lines changed Original file line number Diff line number Diff line change @@ -68,6 +68,8 @@ private:
68
68
// / Used when the file turns out to be a TFile container. The ntuplePath variable is either the ntuple name
69
69
// / or an ntuple name preceded by a directory (`myNtuple` or `foo/bar/myNtuple` or `/foo/bar/myNtuple`)
70
70
RResult<RNTuple> GetNTupleProper (std::string_view ntuplePath);
71
+ // / Loads an RNTuple anchor from a TFile at the given file offset (unzipping it if necessary).
72
+ RResult<RNTuple> GetNTupleProperAtOffset (std::uint64_t keyOffset);
71
73
72
74
// / Searches for a key with the given name and type in the key index of the directory starting at offsetDir.
73
75
// / The offset points to the start of the TDirectory DATA section, without the key and without the name and title
Original file line number Diff line number Diff line change @@ -754,6 +754,14 @@ ROOT::RResult<ROOT::RNTuple> ROOT::Internal::RMiniFileReader::GetNTupleProper(st
754
754
return R__FAIL (" no RNTuple named '" + std::string (ntupleName) + " ' in file '" + fRawFile ->GetUrl () + " '" );
755
755
}
756
756
757
+ auto res = GetNTupleProperAtOffset (offset);
758
+ return res;
759
+ }
760
+
761
+ ROOT::RResult<ROOT::RNTuple> ROOT::Internal::RMiniFileReader::GetNTupleProperAtOffset (std::uint64_t keyOffset)
762
+ {
763
+ auto offset = keyOffset;
764
+ RTFKey key;
757
765
ReadBuffer (&key, sizeof (key), offset);
758
766
offset = key.GetSeekKey () + key.fKeyLen ;
759
767
You can’t perform that action at this time.
0 commit comments