]> https://gitweb.dealii.org/ - dealii.git/commitdiff
Added clear() to TableHandler 231/head
authorFahad Alrashed <fahad@keylock.net>
Sun, 9 Nov 2014 06:39:25 +0000 (00:39 -0600)
committerFahad Alrashed <fahad@keylock.net>
Sun, 9 Nov 2014 06:39:25 +0000 (00:39 -0600)
include/deal.II/base/table_handler.h
source/base/table_handler.cc

index 64753868906777584383fd7f229900d4075133ad..e6d81d920e85a6d6a8fbde52bbb51c87de838451 100644 (file)
@@ -513,6 +513,11 @@ public:
    */
   void write_tex (std::ostream &file, const bool with_header=true) const;
 
+  /**
+   * Clears the values in the table.
+   */
+  void clear ();
+
   /**
    * Read or write the data of this
    * object to or from a stream for
index 8214a0ee0f10b8ab8f103379183864c11a64d383..59a6332649a5bb79e6a73708b3f95b956f48e61b 100644 (file)
@@ -666,6 +666,20 @@ void TableHandler::write_tex (std::ostream &out, const bool with_header) const
 }
 
 
+void TableHandler::clear()
+{
+
+  columns.clear();
+  supercolumns.clear();
+  column_order.clear();
+  tex_supercaptions.clear();
+
+  tex_table_label.clear();
+  tex_table_caption.clear();
+
+}
+
+
 unsigned int TableHandler::n_rows() const
 {
   if (columns.size() == 0)

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.