]> https://gitweb.dealii.org/ - dealii-svn.git/commitdiff
new function get_prefix in LogStream
authorguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 2 May 2001 07:18:30 +0000 (07:18 +0000)
committerguido <guido@0785d39b-7218-0410-832d-ea1e28bc413d>
Wed, 2 May 2001 07:18:30 +0000 (07:18 +0000)
git-svn-id: https://svn.dealii.org/trunk@4515 0785d39b-7218-0410-832d-ea1e28bc413d

deal.II/base/include/base/logstream.h
deal.II/base/source/log.cc

index cd9c44406ce3fd12e1fe48fc44e69fe42261334c..f20f6990826837d5db11578593d7e6126846e581 100644 (file)
@@ -78,6 +78,11 @@ class LogStream
                                      * Gives the file stream.
                                      */
     std::ostream& get_file_stream ();
+
+                                    /**
+                                     * Return the prefix string.
+                                     */
+    const std::string& get_prefix () const;
     
                                     /**
                                      * Push another prefix on the
index 7a79a3ae238624af47bd141d4b9fa0776f486a80..351e30696a0b0f7189ef8347369d9d82838d4924 100644 (file)
@@ -63,6 +63,13 @@ LogStream::get_file_stream()
 }
 
 
+const std::string&
+LogStream::get_prefix() const
+{
+  return prefixes.top();
+}
+
+
 void
 LogStream::push (const std::string& text)
 {
@@ -125,7 +132,7 @@ LogStream::print_line_head()
        }
     }
   
-  const std::string& head = prefixes.top();
+  const std::string& head = get_prefix();
 
   if (prefixes.size() <= std_depth)
     {

In the beginning the Universe was created. This has made a lot of people very angry and has been widely regarded as a bad move.

Douglas Adams


Typeset in Trocchi and Trocchi Bold Sans Serif.