WPILibC++ 2024.1.1-beta-4
wpi::log::DataLogEntry Class Reference

Log entry base class. More...

#include <wpi/DataLog.h>

Inheritance diagram for wpi::log::DataLogEntry:
wpi::log::BooleanArrayLogEntry wpi::log::BooleanLogEntry wpi::log::DoubleArrayLogEntry wpi::log::DoubleLogEntry wpi::log::FloatArrayLogEntry wpi::log::FloatLogEntry wpi::log::IntegerArrayLogEntry wpi::log::IntegerLogEntry wpi::log::ProtobufLogEntry< T > wpi::log::RawLogEntry wpi::log::StringArrayLogEntry wpi::log::StringLogEntry wpi::log::StructArrayLogEntry< T > wpi::log::StructLogEntry< T >

Public Member Functions

 DataLogEntry (const DataLogEntry &)=delete
 
DataLogEntryoperator= (const DataLogEntry &)=delete
 
 DataLogEntry (DataLogEntry &&rhs)
 
DataLogEntryoperator= (DataLogEntry &&rhs)
 
 operator bool () const
 
void SetMetadata (std::string_view metadata, int64_t timestamp=0)
 Updates the metadata for the entry. More...
 
void Finish (int64_t timestamp=0)
 Finishes the entry. More...
 

Protected Member Functions

 DataLogEntry ()=default
 
 DataLogEntry (DataLog &log, std::string_view name, std::string_view type, std::string_view metadata={}, int64_t timestamp=0)
 

Protected Attributes

DataLogm_log = nullptr
 
int m_entry = 0
 

Detailed Description

Log entry base class.

Constructor & Destructor Documentation

◆ DataLogEntry() [1/4]

wpi::log::DataLogEntry::DataLogEntry ( )
protecteddefault

◆ DataLogEntry() [2/4]

wpi::log::DataLogEntry::DataLogEntry ( DataLog log,
std::string_view  name,
std::string_view  type,
std::string_view  metadata = {},
int64_t  timestamp = 0 
)
inlineprotected

◆ DataLogEntry() [3/4]

wpi::log::DataLogEntry::DataLogEntry ( const DataLogEntry )
delete

◆ DataLogEntry() [4/4]

wpi::log::DataLogEntry::DataLogEntry ( DataLogEntry &&  rhs)
inline

Member Function Documentation

◆ Finish()

void wpi::log::DataLogEntry::Finish ( int64_t  timestamp = 0)
inline

Finishes the entry.

Parameters
timestampTime stamp (may be 0 to indicate now)

◆ operator bool()

wpi::log::DataLogEntry::operator bool ( ) const
inlineexplicit

◆ operator=() [1/2]

DataLogEntry & wpi::log::DataLogEntry::operator= ( const DataLogEntry )
delete

◆ operator=() [2/2]

DataLogEntry & wpi::log::DataLogEntry::operator= ( DataLogEntry &&  rhs)
inline

◆ SetMetadata()

void wpi::log::DataLogEntry::SetMetadata ( std::string_view  metadata,
int64_t  timestamp = 0 
)
inline

Updates the metadata for the entry.

Parameters
metadataNew metadata for the entry
timestampTime stamp (may be 0 to indicate now)

Member Data Documentation

◆ m_entry

int wpi::log::DataLogEntry::m_entry = 0
protected

◆ m_log

DataLog* wpi::log::DataLogEntry::m_log = nullptr
protected

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