farm-ng-core
farm_ng::EventLogReaderBinaryImpl Class Reference
Inheritance diagram for farm_ng::EventLogReaderBinaryImpl:
Collaboration diagram for farm_ng::EventLogReaderBinaryImpl:

Public Member Functions

 EventLogReaderBinaryImpl (std::filesystem::path const &log_path)
 
void reset () override
 
auto readBytes (uint64_t n_bytes) -> std::string
 
auto readEventSize () -> uint64_t
 
auto readNextEvent (std::string *payload=nullptr) -> EventLogPos override
 Returns next event. More...
 
auto readPayload (core::proto::Event const &event, std::streampos pos) -> std::string override
 
auto getPath () const -> std::filesystem::path override
 Returns the path including the fileaname. More...
 
- Public Member Functions inherited from farm_ng::EventLogReaderImpl
virtual ~EventLogReaderImpl ()
 https://isocpp.github.io/CppCoreGuidelines/CppCoreGuidelines#Rh-dtor More...
 
std::vector< EventLogPos > const & getIndex ()
 

Public Attributes

std::filesystem::path log_path
 
std::ifstream in
 

Constructor & Destructor Documentation

◆ EventLogReaderBinaryImpl()

farm_ng::EventLogReaderBinaryImpl::EventLogReaderBinaryImpl ( std::filesystem::path const &  log_path)
inline

Member Function Documentation

◆ getPath()

auto farm_ng::EventLogReaderBinaryImpl::getPath ( ) const -> std::filesystem::path
inlineoverridevirtual

Returns the path including the fileaname.

Implements farm_ng::EventLogReaderImpl.

◆ readBytes()

auto farm_ng::EventLogReaderBinaryImpl::readBytes ( uint64_t  n_bytes) -> std::string
inline

◆ readEventSize()

auto farm_ng::EventLogReaderBinaryImpl::readEventSize ( ) -> uint64_t
inline

◆ readNextEvent()

auto farm_ng::EventLogReaderBinaryImpl::readNextEvent ( std::string *  payload = nullptr) -> EventLogPos
inlineoverridevirtual

Returns next event.

Implements farm_ng::EventLogReaderImpl.

◆ readPayload()

auto farm_ng::EventLogReaderBinaryImpl::readPayload ( core::proto::Event const &  event,
std::streampos  pos 
) -> std::string
inlineoverridevirtual

◆ reset()

void farm_ng::EventLogReaderBinaryImpl::reset ( )
inlineoverridevirtual

Member Data Documentation

◆ in

std::ifstream farm_ng::EventLogReaderBinaryImpl::in

◆ log_path

std::filesystem::path farm_ng::EventLogReaderBinaryImpl::log_path

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