0
0
mirror of https://github.com/yse/easy_profiler.git synced 2024-12-27 16:51:22 +08:00

#0 [Core] Added alias for isEnabled, setEnabled functions and macros

This commit is contained in:
Victor Zarubkin 2017-10-04 21:40:23 +03:00
parent 3ab4b9e3c9
commit 5e2d8e3be6

View File

@ -430,6 +430,26 @@ Otherwise, no log messages will be printed.
# define EASY_DEFAULT_PORT 28077 # define EASY_DEFAULT_PORT 28077
# endif # endif
/** Alias for EASY_PROFILER_ENABLE.
Added for clarification.
\sa EASY_PROFILER_ENABLE
\ingroup profiler
*/
#define EASY_START_CAPTURE EASY_PROFILER_ENABLE
/** Alias for EASY_PROFILER_DISABLE.
Added for clarification.
\sa EASY_PROFILER_DISABLE
\ingroup profiler
*/
#define EASY_STOP_CAPTURE EASY_PROFILER_DISABLE
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
////////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////////
@ -955,6 +975,36 @@ namespace profiler {
} // END of namespace main_thread. } // END of namespace main_thread.
/** Alias for isEnabled().
Added for clarification.
\sa isEnabled
\ingroup profiler
*/
EASY_FORCE_INLINE bool isCapturing() { return isEnabled(); }
/** Alias for EASY_PROFILER_ENABLE.
Added for clarification.
\sa EASY_PROFILER_ENABLE
\ingroup profiler
*/
EASY_FORCE_INLINE void startCapture() { EASY_PROFILER_ENABLE; }
/** Alias for EASY_PROFILER_DISABLE.
Added for clarification.
\sa EASY_PROFILER_DISABLE
\ingroup profiler
*/
EASY_FORCE_INLINE void stopCapture() { EASY_PROFILER_DISABLE; }
////////////////////////////////////////////////////////////////////// //////////////////////////////////////////////////////////////////////
} // END of namespace profiler. } // END of namespace profiler.