HDK
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
PDGE_DebugUtils Class Reference

#include <PDGE_DebugUtils.h>

Static Public Member Functions

template<typename... Args>
static void appendLog (const char *fmt, Args &&...args)
 
static void addDependency (PDGE_Dependency *dependency)
 
static void artificialDelay ()
 
static int uniqueId ()
 
static void dumpLog ()
 
static void dumpDOT (UT_WorkBuffer &buffer)
 

Detailed Description

Definition at line 72 of file PDGE_DebugUtils.h.

Member Function Documentation

static void PDGE_DebugUtils::addDependency ( PDGE_Dependency dependency)
inlinestatic

Adds a dependency to the tracking list. This method should be used to inform the debug utils about depdendcies involved during evaluation for the purpose of dumping a DOT graph.

Definition at line 97 of file PDGE_DebugUtils.h.

template<typename... Args>
static void PDGE_DebugUtils::appendLog ( const char *  fmt,
Args &&...  args 
)
inlinestatic

Appends a message to a thread-safe log. Each thread stores its own list of messages along with a unique id for each message. This method expects a format string and variadic arg list, which are handled using UT_Format.

Definition at line 80 of file PDGE_DebugUtils.h.

static void PDGE_DebugUtils::artificialDelay ( )
inlinestatic

Artificially delays dependency evaluation if the PDGE_DEBUG_DELAY value is defined. The value is the number of milliseconds to spend waiting for evaluations.

Definition at line 107 of file PDGE_DebugUtils.h.

static void PDGE_DebugUtils::dumpDOT ( UT_WorkBuffer buffer)
static

Dumps the recorded dependencies as a DOT graph to the specified buffer. PDGE_DEBUG_ENABLE_NAMES should be enabled so that the DOT graph has useful labels. When PDGE_DEBUG_ENABLE_DOT is not enabled this method does nothing.

static void PDGE_DebugUtils::dumpLog ( )
static

Dumps the contents of the log to stdout. Messages are sorted by their unique ID and printed along with the thread ID from which they were initially reported. When PDGE_DEBUG_ENABLE_LOGGING is not enabled this method does nothing.

static int PDGE_DebugUtils::uniqueId ( )
inlinestatic

Returns a unique if for a dependency, if PDGE_DEBUG_ENABLE_IDS is on. This is useful for DOT graph output as it can be used to reduce the label size.

Definition at line 117 of file PDGE_DebugUtils.h.


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