Project
Loading...
Searching...
No Matches
o2::aod::native::PlannedByteSource Class Reference

#include <ReadPlan.h>

Inherits o2::aod::native::ByteSource.

Public Member Functions

 PlannedByteSource (std::shared_ptr< ByteSource > source, std::shared_ptr< ReadPlan > plan)
 
uint64_t size () const override
 
void readInto (uint64_t off, size_t len, void *dst) override
 Throws IoError, or CorruptData when the range is past the end of the file.
 
void readvInto (std::span< ReadRequest > requests) override
 
std::span< const uint8_t > tryMap (uint64_t off, size_t len) override
 A view of the bytes without copying them, if the backend can provide it.
 
uint64_t bytesRead () const override
 
uint64_t readCalls () const override
 
std::string url () const override
 
- Public Member Functions inherited from o2::aod::native::ByteSource
virtual ~ByteSource ()
 
virtual bool canMap () const
 Whether tryMap() provides every range, so that nothing needs reading.
 
virtual bool isRemote () const
 Whether each read is a network round trip, worth hiding behind decoding.
 
virtual void willNeed (uint64_t off, size_t len)
 Hints that a range will be needed soon, or is no longer needed.
 
virtual void dontNeed (uint64_t off, size_t len)
 

Additional Inherited Members

- Static Public Member Functions inherited from o2::aod::native::ByteSource
static std::unique_ptr< ByteSource > open (std::string url, const Options &)
 

Detailed Description

A ByteSource which serves the ranges of a ReadPlan from memory and everything else from the source underneath.

Definition at line 89 of file ReadPlan.h.

Constructor & Destructor Documentation

◆ PlannedByteSource()

o2::aod::native::PlannedByteSource::PlannedByteSource ( std::shared_ptr< ByteSource >  source,
std::shared_ptr< ReadPlan >  plan 
)

Definition at line 172 of file ReadPlan.cxx.

Member Function Documentation

◆ bytesRead()

uint64_t o2::aod::native::PlannedByteSource::bytesRead ( ) const
inlineoverridevirtual

Implements o2::aod::native::ByteSource.

Definition at line 97 of file ReadPlan.h.

◆ readCalls()

uint64_t o2::aod::native::PlannedByteSource::readCalls ( ) const
inlineoverridevirtual

Implements o2::aod::native::ByteSource.

Definition at line 98 of file ReadPlan.h.

◆ readInto()

void o2::aod::native::PlannedByteSource::readInto ( uint64_t  off,
size_t  len,
void *  dst 
)
overridevirtual

Throws IoError, or CorruptData when the range is past the end of the file.

Implements o2::aod::native::ByteSource.

Definition at line 183 of file ReadPlan.cxx.

◆ readvInto()

void o2::aod::native::PlannedByteSource::readvInto ( std::span< ReadRequest >  requests)
overridevirtual

Implements o2::aod::native::ByteSource.

Definition at line 193 of file ReadPlan.cxx.

◆ size()

uint64_t o2::aod::native::PlannedByteSource::size ( ) const
inlineoverridevirtual

Implements o2::aod::native::ByteSource.

Definition at line 93 of file ReadPlan.h.

◆ tryMap()

std::span< const uint8_t > o2::aod::native::PlannedByteSource::tryMap ( uint64_t  off,
size_t  len 
)
overridevirtual

A view of the bytes without copying them, if the backend can provide it.

Reimplemented from o2::aod::native::ByteSource.

Definition at line 177 of file ReadPlan.cxx.

◆ url()

std::string o2::aod::native::PlannedByteSource::url ( ) const
inlineoverridevirtual

Implements o2::aod::native::ByteSource.

Definition at line 99 of file ReadPlan.h.


The documentation for this class was generated from the following files: