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: 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//#
27//# $Id$
28
29#ifndef MS_MSANTENNAINDEX_H
30#define MS_MSANTENNAINDEX_H
31
32//# includes
33#include <casacore/casa/aips.h>
34#include <casacore/ms/MeasurementSets/MSAntenna.h>
35#include <casacore/ms/MeasurementSets/MSAntennaColumns.h>
36#include <casacore/casa/Arrays/Vector.h>
37#include <casacore/casa/BasicSL/String.h>
38
39namespace casacore { //# NAMESPACE CASACORE - BEGIN
40
41//# forward declarations
42
43// <summary>
44// Class to handle lookup or indexing into a MS ANTENNA subtable
45// </summary>
46
47// <use visibility=export>
48//
49// <reviewed reviewer="" date="yyyy/mm/dd" tests="" demos="">
50// </reviewed>
51
52// <prerequisite>
53// <li> MeasurementSet
54// <li> MSAntenna
55// </prerequisite>
56//
57// <etymology>
58// From "MeasurementSet", "ANTENNA subtable" and "index".
59// </etymology>
60//
61// <synopsis>
62// This class provides lookup and indexing into an MS ANTENNA
63// subtable. These services include returning rows numbers
64// (which for the ANTENNA subtable are ANTENNA_ID's) associated
65// with specific data in the subtable.
66// </synopsis>
67//
68// <example>
69// </example>
70//
71// <motivation>
72// Collect together all subtable indexing and lookup for the
73// ANTENNA subtable, for encapsulation and efficiency.
74// </motivation>
75//
76// <thrown>
77// <li>
78// <li>
79// </thrown>
80//
81
83{
84public:
85 // Construct from an MS ANTENNA subtable
86 MSAntennaIndex(const MSAntenna &antenna);
87
88 // Null destructor
89 virtual ~MSAntennaIndex() {}
90
91 // Look up ANTENNA_ID's for a given a regular expression or pattern
93 // Look up ANTENNA_ID's for a given antenna name, or set of antenna names
96
97 // Look up ANTENNA_ID's for a given antenna station
101
102 // Look up ANTENNA_ID's for a given antenna and station name pair
104 const String& station);
105
107private:
108 // Default constructor
110 // ANTENNA subtable column accessor
112
113 // Vector cache of antenna id's
116};
117
118
119} //# NAMESPACE CASACORE - END
120
121#endif
122
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:225
this file contains all the compiler specific defines
Definition mainpage.dox:28
TableExprNode pattern(const TableExprNode &node)
Definition ExprNode.h:1487
const Bool False
Definition aipstype.h:44
TableExprNode regex(const TableExprNode &node)
Functions for regular expression matching and pattern matching.
Definition ExprNode.h:1483
int Int
Definition aipstype.h:50
bool Bool
Define the standard types used by Casacore.
Definition aipstype.h:42