From 2fc039c2b92c96c89c52fab9f9f56790aa01cd33 Mon Sep 17 00:00:00 2001
From: Remy Prechelt <prechelt@hawaii.edu>
Date: Sat, 24 Oct 2020 23:20:30 -1000
Subject: [PATCH] Add GetOutput() method to base interface.

---
 Outputs/BaseOutput.h                    |  5 +++++
 Outputs/ObservationPlaneWriterParquet.h | 16 ++++++++--------
 2 files changed, 13 insertions(+), 8 deletions(-)

diff --git a/Outputs/BaseOutput.h b/Outputs/BaseOutput.h
index 53f01347b..eee5740e7 100644
--- a/Outputs/BaseOutput.h
+++ b/Outputs/BaseOutput.h
@@ -52,6 +52,11 @@ namespace corsika::output {
      * Get the configuration of this output.
      */
     virtual YAML::Node GetConfig() const = 0;
+
+    /**
+     * Get final text outputs for the config file.
+     */
+    virtual YAML::Node GetOutput() = 0;
   };
 
 } // namespace corsika::output
diff --git a/Outputs/ObservationPlaneWriterParquet.h b/Outputs/ObservationPlaneWriterParquet.h
index 3da21460c..8c27b099d 100644
--- a/Outputs/ObservationPlaneWriterParquet.h
+++ b/Outputs/ObservationPlaneWriterParquet.h
@@ -52,20 +52,22 @@ namespace corsika::output {
     /**
      * Called at the start of each event/shower.
      */
-      void StartOfEvent() final { ++event_;
-      }
+    void StartOfEvent() final { ++event_; }
 
     /**
      * Called at the end of each event/shower.
      */
-      void EndOfEvent() final {
-      }
+    void EndOfEvent() final {}
 
     /**
      * Called at the end of each run.
      */
-      void EndOfRun() final { streamer_.Close();
-      }
+    void EndOfRun() final { streamer_.Close(); }
+
+    /**
+     * Get final text outputs for the config file.
+     */
+    YAML::Node GetOutput() final { return YAML::Node(); }
 
   protected:
     /**
@@ -79,10 +81,8 @@ namespace corsika::output {
       // write the next row
       writer_ << event_ << static_cast<int>(particles::GetPDG(pid)) << energy / 1_eV
               << distance / 1_m << parquet::EndRow;
-
     }
 
-
     std::string const name_; ///< The name of this output.
 
   private:
-- 
GitLab