11 #ifndef __ProcHistory_h
12 #define __ProcHistory_h
14 #include "Pulsar/ArchiveExtension.h"
15 #include "TextInterface.h"
19 class ProcHistory :
public Archive::Extension {
27 ProcHistory* clone ()
const {
return new ProcHistory( *
this ); }
36 Interface( ProcHistory *s_instance = NULL );
40 std::string get_short_name ()
const {
return "hist"; }
56 Interface( row *s_instance = NULL );
62 std::string get_date_pro ()
const {
return date_pro; }
63 std::string get_proc_cmd ()
const {
return proc_cmd; }
64 std::string get_pol_type ()
const {
return pol_type; }
65 int get_nsub ()
const {
return nsub; }
66 int get_npol ()
const {
return npol; }
67 int get_nbin ()
const {
return nbin; }
68 int get_nbin_prd ()
const {
return nbin_prd; }
69 double get_tbin ()
const {
return tbin; }
70 double get_ctr_freq ()
const {
return ctr_freq; }
71 int get_nchan ()
const {
return nchan; }
72 double get_chan_bw ()
const {
return chan_bw; }
73 double get_ref_freq ()
const {
return ref_freq; }
74 double get_dispersion_measure ()
const {
return dispersion_measure; }
75 double get_rotation_measure ()
const {
return rotation_measure; }
76 int get_pr_corr ()
const {
return pr_corr; }
77 int get_fd_corr ()
const {
return fd_corr; }
78 int get_be_corr ()
const {
return be_corr; }
79 int get_rm_corr ()
const {
return rm_corr; }
80 int get_dedisp ()
const {
return dedisp; }
81 int get_aux_rm_corr ()
const {
return aux_rm_corr; }
82 int get_aux_dm_corr ()
const {
return aux_dm_corr; }
83 std::string get_dds_mthd ()
const {
return dds_mthd; }
84 std::string get_sc_mthd ()
const {
return sc_mthd; }
85 std::string get_cal_mthd ()
const {
return cal_mthd; }
86 std::string get_cal_file ()
const {
return cal_file; }
87 std::string get_rfi_mthd ()
const {
return rfi_mthd; }
88 std::string get_aux_rm_model ()
const {
return aux_rm_model; }
89 std::string get_aux_dm_model ()
const {
return aux_dm_model; }
90 std::string
get_scale ()
const {
return scale; }
105 double dispersion_measure;
106 double rotation_measure;
116 std::string dds_mthd;
118 std::string cal_mthd;
119 std::string cal_file;
120 std::string rfi_mthd;
122 std::string aux_rm_model;
123 std::string aux_dm_model;
129 std::vector<row> rows;
132 unsigned get_nrow ()
const;
135 row* get_row (
unsigned i);
136 const row* get_row (
unsigned i)
const;
138 std::string command_str;
139 std::string the_cal_mthd;
140 std::string the_sc_mthd;
141 std::string the_cal_file;
142 std::string the_rfi_mthd;
144 ProcHistory::row& get_first ();
145 ProcHistory::row& get_last ();
147 void set_command_str (
const std::string&);
148 std::string get_command_str ();
149 void set_cal_mthd (
const std::string&);
150 std::string get_cal_mthd ();
151 void set_sc_mthd (
const std::string&);
152 std::string get_sc_mthd ();
153 void set_cal_file (
const std::string&);
154 std::string get_cal_file ()
const {
return the_cal_file; }
155 void set_rfi_mthd (
const std::string&);
156 std::string get_rfi_mthd ();
158 int get_last_nbin_prd ()
const {
return rows.back().nbin_prd; }
159 double get_last_tbin ()
const {
return rows.back().tbin; }
160 double get_last_chan_bw ()
const {
return rows.back().chan_bw; }
162 void add_blank_row ();
166 void check_irow (
unsigned irow)
const;