]> git.mxchange.org Git - simgear.git/commitdiff
- implemented set/get_log_classes and set/get_log_priority
authorcurt <curt>
Tue, 20 Nov 2001 20:56:53 +0000 (20:56 +0000)
committercurt <curt>
Tue, 20 Nov 2001 20:56:53 +0000 (20:56 +0000)
simgear/debug/logstream.cxx
simgear/debug/logstream.hxx

index 0a6e64f461c22358843f94d6e526665462fde686..deca69939aa6c0bbcce7e22b3dc4be06cd298d96 100644 (file)
@@ -56,6 +56,30 @@ logbuf::set_log_level( sgDebugClass c, sgDebugPriority p )
     logPriority = p;
 }
 
+void
+logbuf::set_log_classes (sgDebugClass c)
+{
+    logClass = c;
+}
+
+sgDebugClass
+logbuf::get_log_classes ()
+{
+    return logClass;
+}
+
+void
+logbuf::set_log_priority (sgDebugPriority p)
+{
+    logPriority = p;
+}
+
+sgDebugPriority
+logbuf::get_log_priority ()
+{
+    return logPriority;
+}
+
 void
 logstream::setLogLevels( sgDebugClass c, sgDebugPriority p )
 {
index 6d89620f9da463e1a4d45bc87b60bbf6c97adb29..5b57d50f0f8f977cb162cd90ed2a72a364291b1f 100644 (file)
@@ -105,6 +105,35 @@ public:
      */
     static void set_log_level( sgDebugClass c, sgDebugPriority p );
 
+
+    /**
+     * Set the allowed logging classes.
+     * @param c All enabled logging classes anded together.
+     */
+    static void set_log_classes (sgDebugClass c);
+
+
+    /**
+     * Get the logging classes currently enabled.
+     * @return All enabled debug logging anded together.
+     */
+    static sgDebugClass get_log_classes ();
+
+
+    /**
+     * Set the logging priority.
+     * @param c The priority cutoff for logging messages.
+     */
+    static void set_log_priority (sgDebugPriority p);
+
+
+    /**
+     * Get the current logging priority.
+     * @return The priority cutoff for logging messages.
+     */
+    static sgDebugPriority get_log_priority ();
+
+
     /**
      * Set the stream buffer
      * @param sb stream buffer