HDK
|
#include <scopeDescription.h>
Public Member Functions | |
TF_API | TfScopeDescription (std::string const &description, TfCallContext const &context=TfCallContext()) |
TF_API | TfScopeDescription (std::string &&description, TfCallContext const &context=TfCallContext()) |
TF_API | TfScopeDescription (char const *description, TfCallContext const &context=TfCallContext()) |
TF_API | ~TfScopeDescription () |
TF_API void | SetDescription (std::string const &description) |
TF_API void | SetDescription (std::string &&description) |
TF_API void | SetDescription (char const *description) |
Friends | |
TfScopeDescription * | Tf_GetPreviousScopeDescription (TfScopeDescription *d) |
char const * | Tf_GetScopeDescriptionText (TfScopeDescription *d) |
TfCallContext const & | Tf_GetScopeDescriptionContext (TfScopeDescription *d) |
This class is used to provide high-level descriptions about scopes of execution that could possibly block, or to provide relevant information about high-level action that would be useful in a crash report.
This class is reasonably fast to use, especially if the message strings are not dynamically created, however it should not be used in very highly performance sensitive contexts. The cost to push & pop is essentially a TLS lookup plus a couple of atomic operations.
Definition at line 49 of file scopeDescription.h.
|
explicit |
Construct with a description. Push description on the stack of descriptions for this thread. Caller guarantees that the string description
lives at least as long as this TfScopeDescription object.
|
explicit |
Construct with a description. Push description on the stack of descriptions for this thread. This object adopts ownership of the rvalue description
.
|
explicit |
Construct with a description. Push description on the stack of descriptions for this thread. Caller guarantees that the string description
lives at least as long as this TfScopeDescription object.
TF_API TfScopeDescription::~TfScopeDescription | ( | ) |
Destructor. Pop the description stack in this thread.
TF_API void TfScopeDescription::SetDescription | ( | std::string const & | description | ) |
Replace the description stack entry for this scope description. Caller guarantees that the string description
lives at least as long as this TfScopeDescription object.
TF_API void TfScopeDescription::SetDescription | ( | std::string && | description | ) |
Replace the description stack entry for this scope description. This object adopts ownership of the rvalue description
.
Replace the description stack entry for this scope description. Caller guarantees that the string description
lives at least as long as this TfScopeDescription object.
|
friend |
Definition at line 96 of file scopeDescription.h.
|
friend |
Definition at line 104 of file scopeDescription.h.
|
friend |
Definition at line 100 of file scopeDescription.h.