ObsExtension.h
1 //-*-C++-*-
2 /***************************************************************************
3  *
4  * Copyright (C) 2003 by Willem van Straten
5  * Licensed under the Academic Free License version 2.1
6  *
7  ***************************************************************************/
8 
9 // psrchive/Base/Extensions/Pulsar/ObsExtension.h
10 
11 #ifndef __ObsExtension_h
12 #define __ObsExtension_h
13 
14 #include "Pulsar/ArchiveExtension.h"
15 #include "TextInterface.h"
16 
17 namespace Pulsar {
18 
20 
24  class ObsExtension : public Pulsar::Archive::Extension {
25 
26  public:
27 
30 
32  ObsExtension (const ObsExtension& extension);
33 
35  const ObsExtension& operator= (const ObsExtension& extension);
36 
38  ~ObsExtension ();
39 
41  ObsExtension* clone () const { return new ObsExtension( *this ); }
42 
45 
46  // Text interface to a ObsExtension object
47  class Interface : public TextInterface::To<ObsExtension>
48  {
49  public:
50  Interface( ObsExtension *s_instance = NULL );
51  };
52 
54  std::string get_short_name () const { return "obs"; }
55 
56  // get methods
57  std::string get_observer() const { return observer; }
58  void set_observer(const std::string& _observer) { observer = _observer; }
59 
60  std::string get_affiliate() const { return affiliation; }
61 
62  std::string get_project_ID() const { return project_ID; }
63  void set_project_ID (const std::string& pid) { project_ID = pid; }
64 
66 
68  std::string observer;
69 
71  std::string affiliation;
72 
74  std::string project_ID;
75  };
76 
77 }
78 
79 #endif
const ObsExtension & operator=(const ObsExtension &extension)
Operator =.
Definition: ObsExtension.C:30
std::string affiliation
Observer's affilitation.
Definition: ObsExtension.h:81
TextInterface::Parser * get_interface()
Return a text interfaces that can be used to access this instance.
Definition: ObsExtension.C:45
std::string project_ID
Project ID.
Definition: ObsExtension.h:84
ObsExtension()
Default constructor.
Definition: ObsExtension.C:11
Observation Information Extension.
Definition: ObsExtension.h:29
std::string observer
Observer name.
Definition: ObsExtension.h:78
ObsExtension * clone() const
Clone method.
Definition: ObsExtension.h:51
~ObsExtension()
Destructor.
Definition: ObsExtension.C:40
std::string get_short_name() const
Return an abbreviated name that can be typed relatively quickly.
Definition: ObsExtension.h:64
Definition: ArchiveExtension.h:28
Defines the PSRCHIVE library.
Definition: CalSource.h:17

Generated using doxygen 1.8.17