MCPcopy Create free account
hub / github.com/catboost/catboost / GetRegion

Method GetRegion

library/cpp/on_disk/chunks/reader.h:35–39  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

33
34 template <typename T>
35 TArrayRef<const T> GetRegion(size_t index) const {
36 size_t len = GetBlockLen(index);
37 Y_ENSURE(len % sizeof(T) == 0, "wrong data padding");
38 return TArrayRef<const T>(reinterpret_cast<const T*>(GetBlock(index)), len / sizeof(T));
39 }
40
41 inline size_t GetBlocksCount() const {
42 return Offsets.size();

Callers

nothing calls this directly

Calls 1

GetBlockFunction · 0.85

Tested by

no test coverage detected