casacore
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
MeasuresProxy.h
Go to the documentation of this file.
1 //# MeasuresProxy.h: This class gives a high-level interface to Measures
2 //# Copyright (C) 2006
3 //# Associated Universities, Inc. Washington DC, USA.
4 //#
5 //# This program is free software; you can redistribute it and/or modify it
6 //# under the terms of the GNU General Public License as published by the Free
7 //# Software Foundation; either version 2 of the License, or (at your option)
8 //# any later version.
9 //#
10 //# This program is distributed in the hope that it will be useful, but WITHOUT
11 //# ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
13 //# more details.
14 //#
15 //# You should have received a copy of the GNU General Public License along
16 //# with this program; if not, write to the Free Software Foundation, Inc.,
17 //# 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18 //#
19 //# Correspondence concerning AIPS++ should be addressed as follows:
20 //# Internet email: aips2-request@nrao.edu.
21 //# Postal address: AIPS++ Project Office
22 //# National Radio Astronomy Observatory
23 //# 520 Edgemont Road
24 //# Charlottesville, VA 22903-2475 USA
25 //#
26 //# $Id$
27 
28 #ifndef MEASURES_MEASURESPROXY_H
29 #define MEASURES_MEASURESPROXY_H
30 
31 //# Includes
32 
33 #include <casacore/casa/aips.h>
40 
41 //# Forward declarations
42 namespace casacore { //# NAMESPACE CASACORE - BEGIN
43 class String;
44 class MeasureHolder;
45 class MeasComet;
46 
48 {
49 public:
50  MeasuresProxy();
51  virtual ~MeasuresProxy();
52  Record measure(const Record& rec, const String& str, const Record& form);
53  Bool doframe(const Record& rec);
54  String dirshow(const Record& rec);
55  Record doptorv(const Record& rec, const String& str);
56  Record doptofreq(const Record& rec, const String& str,
57  const Quantity& form);
58  Record todop(const Record& rec, const Quantity& form);
59  Record torest(const Record& rec, const Record& form);
63  Record observatory(const String& str);
64  Record source(const String& str);
65  Record line(const String& str);
66  Record alltyp(const Record& rec);
67  Quantum<Vector<Double> > posangle(const Record& lrec, const Record& rrec);
68  Quantum<Vector<Double> > separation(const Record& lrec, const Record& rrec);
69  Record uvw(const Record& mhrec);
70  Record expand(const Record& mhrec);
71 
72 private:
73  String vec2str(const Vector<String>& lst);
74  Bool doFrame(const MeasureHolder &in);
75  Bool doFrame(const String &in);
76  Bool makeMeasure(String &error, MeasureHolder &out,
77  const MeasureHolder &in, const String &outref,
78  const Record &off);
79  Bool toUvw(String &error, MeasureHolder &out,
80  Vector<Double> &xyz, Vector<Double> &dot,
81  const MeasureHolder &in);
82  Bool expandIt(String &error, MeasureHolder &out,
83  Vector<Double> &xyz,
84  const MeasureHolder &in);
85  MeasureHolder rec2mh(const Record& rec);
86  Record mh2rec(const MeasureHolder& mh);
87 
88  static String getMeasureType(const Record &in);
89 
90  //# Data
91  // The globally used MeasFrame for this DO
93  // The current comet class
95 
96 };
97 
98 } //# NAMESPACE CASACORE - END
99 
100 #endif
Record doptorv(const Record &rec, const String &str)
String vec2str(const Vector< String > &lst)
A 1-D Specialization of the Array class.
Definition: ArrayFwd.h:9
Position for comets and other solar system bodies.
Definition: MeasComet.h:106
Record expand(const Record &mhrec)
Record observatory(const String &str)
Bool expandIt(String &error, MeasureHolder &out, Vector< Double > &xyz, const MeasureHolder &in)
Bool doframe(const Record &rec)
Quantum< Vector< Double > > separation(const Record &lrec, const Record &rrec)
String dirshow(const Record &rec)
Container for Measure frame.
Definition: MeasFrame.h:137
Bool doFrame(const MeasureHolder &in)
Vector< String > obslist()
Record line(const String &str)
Record source(const String &str)
Record torest(const Record &rec, const Record &form)
Bool toUvw(String &error, MeasureHolder &out, Vector< Double > &xyz, Vector< Double > &dot, const MeasureHolder &in)
MeasFrame frame_p
The globally used MeasFrame for this DO.
Definition: MeasuresProxy.h:92
Bool makeMeasure(String &error, MeasureHolder &out, const MeasureHolder &in, const String &outref, const Record &off)
Vector< String > linelist()
Record measure(const Record &rec, const String &str, const Record &form)
Vector< String > srclist()
Quantum< Vector< Double > > posangle(const Record &lrec, const Record &rrec)
A holder for Measures to enable record conversions.
A hierarchical collection of named fields of various types.
Definition: Record.h:180
bool Bool
Define the standard types used by Casacore.
Definition: aipstype.h:42
Record todop(const Record &rec, const Quantity &form)
static String getMeasureType(const Record &in)
String: the storage and methods of handling collections of characters.
Definition: String.h:225
MeasComet * pcomet_p
The current comet class.
Definition: MeasuresProxy.h:94
MeasureHolder rec2mh(const Record &rec)
Record uvw(const Record &mhrec)
Record doptofreq(const Record &rec, const String &str, const Quantity &form)
Record alltyp(const Record &rec)
Record mh2rec(const MeasureHolder &mh)