casacore
Loading...
Searching...
No Matches
MSAntennaIndex.h
Go to the documentation of this file.
1//# MSAntennaIndex: index or lookup in a MeasurementSet ANTENNA subtable
2//# Copyright (C) 2000,2001,2002
3//# Associated Universities, Inc. Washington DC, USA.
4//#
5//# This library is free software; you can redistribute it and/or modify it
6//# under the terms of the GNU Library General Public License as published by
7//# the Free Software Foundation; either version 2 of the License, or (at your
8//# option) any later version.
9//#
10//# This library 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 Library General Public
13//# License for more details.
14//#
15//# You should have received a copy of the GNU Library General Public License
16//# along with this library; if not, write to the Free Software Foundation,
17//# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18//#
19//# Correspondence concerning AIPS++ should be addressed as follows:
20//# Internet email: casa-feedback@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#ifndef MS_MSANTENNAINDEX_H
27#define MS_MSANTENNAINDEX_H
28
29//# includes
30#include <casacore/casa/aips.h>
31#include <casacore/ms/MeasurementSets/MSAntenna.h>
32#include <casacore/ms/MeasurementSets/MSAntennaColumns.h>
33#include <casacore/casa/Arrays/Vector.h>
34#include <casacore/casa/BasicSL/String.h>
35
36namespace casacore { //# NAMESPACE CASACORE - BEGIN
37
38//# forward declarations
39
40// <summary>
41// Class to handle lookup or indexing into a MS ANTENNA subtable
42// </summary>
43
44// <use visibility=export>
45//
46// <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos="">
47// </reviewed>
48
49// <prerequisite>
50// <li> MeasurementSet
51// <li> MSAntenna
52// </prerequisite>
53//
54// <etymology>
55// From "MeasurementSet", "ANTENNA subtable" and "index".
56// </etymology>
57//
58// <synopsis>
59// This class provides lookup and indexing into an MS ANTENNA
60// subtable. These services include returning rows numbers
61// (which for the ANTENNA subtable are ANTENNA_ID's) associated
62// with specific data in the subtable.
63// </synopsis>
64//
65// <example>
66// </example>
67//
68// <motivation>
69// Collect together all subtable indexing and lookup for the
70// ANTENNA subtable, for encapsulation and efficiency.
71// </motivation>
72//
73// <thrown>
74// <li>
75// <li>
76// </thrown>
77//
78
80{
81public:
82 // Construct from an MS ANTENNA subtable
83 MSAntennaIndex(const MSAntenna &antenna);
84
85 // Null destructor
86 virtual ~MSAntennaIndex() {}
87
88 // Look up ANTENNA_ID's for a given a regular expression or pattern
90 // Look up ANTENNA_ID's for a given antenna name, or set of antenna names
93
94 // Look up ANTENNA_ID's for a given antenna station
98
99 // Look up ANTENNA_ID's for a given antenna and station name pair
101 const String& station);
102
104private:
105 // Default constructor
107 // ANTENNA subtable column accessor
109
110 // Vector cache of antenna id's
113};
114
115
116} //# NAMESPACE CASACORE - END
117
118#endif
119
Vector< Int > matchAntennaName(const String &name)
Look up ANTENNA_ID's for a given antenna name, or set of antenna names.
Vector< Int > matchAntennaRegexOrPattern(const String &pattern, const Bool regex=False)
Look up ANTENNA_ID's for a given a regular expression or pattern.
virtual ~MSAntennaIndex()
Null destructor.
Vector< Int > matchStationName(const Vector< String > &station)
Vector< Int > matchId(const Vector< Int > &sourceId)
Vector< Int > matchAntennaNameAndStation(const String &name, const String &station)
Look up ANTENNA_ID's for a given antenna and station name pair.
Vector< Int > matchStationName(const String &station)
Vector< Int > matchStationRegexOrPattern(const String &pattern, const Bool regex=False)
Look up ANTENNA_ID's for a given antenna station.
MSAntennaIndex(const MSAntenna &antenna)
Construct from an MS ANTENNA subtable.
Vector< Int > antennaIds_p
Vector cache of antenna id's.
MSAntennaIndex()
Default constructor.
MSAntennaColumns msAntennaCols_p
ANTENNA subtable column accessor.
Vector< Int > matchAntennaName(const Vector< String > &names)
String: the storage and methods of handling collections of characters.
Definition String.h:223
this file contains all the compiler specific defines
Definition mainpage.dox:28
TableExprNode pattern(const TableExprNode &node)
Definition ExprNode.h:1491
const Bool False
Definition aipstype.h:42
TableExprNode regex(const TableExprNode &node)
Functions for regular expression matching and pattern matching.
Definition ExprNode.h:1487
int Int
Definition aipstype.h:48
bool Bool
Define the standard types used by Casacore.
Definition aipstype.h:40