/*++

Module Name:

    Trace.h

Abstract:

    Header file for the debug tracing related function defintions and macros.

Environment:

    User mode

--*/

//
// Define the tracing flags.
//
// Tracing GUID - {FB4C7DE7-81FB-4E56-A41C-77AED5FB76DE}
//

#define WPP_CONTROL_GUIDS                       \
    WPP_DEFINE_CONTROL_GUID(                    \
        PublicDNSPluginServiceTraceGuid, (FB4C7DE7, 81FB, 4E56, A41C, 77AED5FB76DE), \
                                                \
        WPP_DEFINE_BIT(MYAPP_ALL_INFO)          \
        WPP_DEFINE_BIT(TRACE_COMMRCFG)          \
        WPP_DEFINE_BIT(TRACE_ABOUT_BOX)         \
        WPP_DEFINE_BIT(TRACE_PLUGIN_CONFIG)     \
        WPP_DEFINE_BIT(TRACE_PLUGIN_CONFIG_DLG) \
        WPP_DEFINE_BIT(TRACE_RTSDD_MESSAGE_BOX) \
        WPP_DEFINE_BIT(TRACE_WAIT_DIALOG)       \
        WPP_DEFINE_BIT(TRACE_WAIT_THREAD)       \
        WPP_DEFINE_BIT(FILE_TRACE)              \
        )                             

#define WPP_FLAG_LEVEL_LOGGER(flag, level)                             \
    WPP_LEVEL_LOGGER(flag)

#define WPP_FLAG_LEVEL_ENABLED(flag, level)                            \
    (WPP_LEVEL_ENABLED(flag) &&                                        \
     WPP_CONTROL(WPP_BIT_ ## flag).Level >= level)

#define WPP_LEVEL_FLAGS_LOGGER(lvl,flags) \
           WPP_LEVEL_LOGGER(flags)
               
#define WPP_LEVEL_FLAGS_ENABLED(lvl, flags) \
           (WPP_LEVEL_ENABLED(flags) && WPP_CONTROL(WPP_BIT_ ## flags).Level >= lvl)

//
// This comment block is scanned by the trace preprocessor to define our
// Trace function.
//
// begin_wpp config
// FUNC Trace{FLAG=MYAPP_ALL_INFO}(LEVEL, MSG, ...);
// FUNC TraceEvents(LEVEL, FLAGS, MSG, ...);
// end_wpp
//
