NVIDIA DRIVE OS Linux SDK API Reference

5.1.15.0 Release
For Test and Development only

Detailed Description

Defines the public interfaces to control the logging/tracing of the NvSIPL Query (libnvsipl_query.so) for debugging. The interfaces are implemented by class CNvSIPLQueryTrace.

Definition at line 31 of file NvSIPLQueryTrace.hpp.

Public Types

enum  TraceLevel {
  LevelNone = 0,
  LevelError,
  LevelCritical,
  LevelInfo,
  LevelVerbose,
  LevelSpew,
  LevelAll
}
 Defines tracing/logging levels. More...
 
using TraceFuncPtr = void(*)(const char *, int)
 

Public Member Functions

virtual void SetHook (TraceFuncPtr traceHook, bool bCallDefaultRenderer)=0
 Sets a callable trace hook. More...
 
virtual void SetLevel (TraceLevel eLevel)=0
 Sets the log level. More...
 
virtual void DisableLineInfo (void)=0
 Disable line info (FUNCTION : LINE: ) prefix. More...
 
virtual ~INvSIPLQueryTrace ()=default
 Default destructor. More...
 

Static Public Member Functions

static INvSIPLQueryTraceGetInstance (void)
 Gets a handle to INvSIPLTrace instance. More...
 

Member Typedef Documentation

◆ TraceFuncPtr

using nvsipl::INvSIPLQueryTrace::TraceFuncPtr = void(*)(const char*, int)

Definition at line 47 of file NvSIPLQueryTrace.hpp.

Member Enumeration Documentation

◆ TraceLevel

Defines tracing/logging levels.

Enumerator
LevelNone 

Indicates logging is turned off.

LevelError 

Indicates logging is turned on for errors.

LevelCritical 

Indicates logging is turned on for critical messages.

LevelInfo 

Indicates logging is turned on for information level messages.

LevelVerbose 

Indicates logging is turned on for verbose information.

LevelSpew 

Indicates logging is turned on for very verbose information.

LevelAll 

Indicates logging is turned on for all messages.

Definition at line 36 of file NvSIPLQueryTrace.hpp.

Constructor & Destructor Documentation

◆ ~INvSIPLQueryTrace()

virtual nvsipl::INvSIPLQueryTrace::~INvSIPLQueryTrace ( )
virtualdefault

Default destructor.

Member Function Documentation

◆ DisableLineInfo()

virtual void nvsipl::INvSIPLQueryTrace::DisableLineInfo ( void  )
pure virtual

Disable line info (FUNCTION : LINE: ) prefix.

Function to disable line information prefix. Each log/trace is prefixed with function name and the line number. Calling this function will disable the prefix.

◆ GetInstance()

static INvSIPLQueryTrace* nvsipl::INvSIPLQueryTrace::GetInstance ( void  )
static

Gets a handle to INvSIPLTrace instance.

Static function to get a handle to singleton INvSIPLTrace implementation object.

Returns
pointer to INvSIPLTrace.

◆ SetHook()

virtual void nvsipl::INvSIPLQueryTrace::SetHook ( TraceFuncPtr  traceHook,
bool  bCallDefaultRenderer 
)
pure virtual

Sets a callable trace hook.

Function to set a callable hook to receive the messages from the library.

Parameters
[in]traceHookstd::function object, which could be a functor, function pointer, or a lambda. The function object should take const @ char* message and number of chars as arguments.
[in]bCallDefaultRendererBoolean flag indicating if the message should be printed to the default renderer (stderr).

◆ SetLevel()

virtual void nvsipl::INvSIPLQueryTrace::SetLevel ( TraceLevel  eLevel)
pure virtual

Sets the log level.

Function to set the level of logging. Each trace statement specifies a trace level for that statement, and all traces with a level greater than or equal to the current application trace level will be rendered at runtime. Traces with a level below the application trace level will be ignored. The application trace level can be changed at any time to render additional or fewer trace statements.

Parameters
[in]eLevelTrace level TraceLevel.

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