31 #ifdef MSQ_USE_OLD_STD_HEADERS
37 #ifdef MSQ_USE_OLD_IO_HEADERS
38 # include <iostream.h>
43 #ifdef MSQ_USE_OLD_C_HEADERS
98 static void enable(
unsigned flag ) {
set( flag,
true ); }
102 static void set(
unsigned flag,
bool state );
104 static bool get(
unsigned flag );
110 static msq_stdio::ostream&
get_stream(
unsigned flag );
112 static void set_stream(
unsigned flag, msq_stdio::ostream& stream );
120 void print(
const char* format, ... ) const
122 __attribute__ ((format (printf, 2, 3)))
138 static msq_std::vector<msq_stdio::ostream*>
streams;
145 #ifdef MSQ_ENABLE_DEBUG
146 # define MSQ_DBG(flag) Mesquite::MsqDebug::get(flag)
148 # define MSQ_DBG(flag) false
158 #define MSQ_DBGOUT(flag) if (MSQ_DBG(flag)) Mesquite::MsqDebug::get_stream(flag)
167 #define MSQ_PRINT(flag) if (MSQ_DBG(flag)) Mesquite::MsqDebug::FormatPrinter(flag).print
static msq_std::vector< msq_stdio::ostream * > streams
static msq_stdio::ostream & get_stream(unsigned flag)
Get the output stream to be used for a given debug flag.
static msq_std::vector< bool > flags
static void set(unsigned flag, bool state)
Set a debug flag.
static InitializeFlags init
static void set_stream(unsigned flag, msq_stdio::ostream &stream)
Set the output stream to be used for a given debug flag.
static void enable(unsigned flag)
Enable a debug flag.
static void disable(unsigned flag)
Disable a debug flag.
Run-time activation/deactivation of debug flags.
static void disable_all()
Disable all debug streams.