casacore
MSAntennaGram.h
Go to the documentation of this file.
1//# MSAntennaGram.h: Grammar for ms antenna sub-expressions
2//# Copyright (C) 1998
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//# $Id$
27
28#ifndef MS_MSANTENNAGRAM_H
29#define MS_MSANTENNAGRAM_H
30
31
32//# Includes
33#include <casacore/casa/aips.h>
34#include <casacore/casa/BasicSL/String.h>
35#include <casacore/casa/Arrays/Matrix.h>
36#include <casacore/ms/MSSel/MSAntennaParse.h> // routines used by bison actions
37
38namespace casacore { //# NAMESPACE CASACORE - BEGIN
39
40//# Forward Declarations
41class MeasurementSet;
42class TableExprNode;
43
44// <summary>
45// Global functions for flex/bison scanner/parser for MSAntennaGram
46// </summary>
47
48// <use visibility=local>
49
50// <reviewed reviewer="" date="" tests="">
51// </reviewed>
52
53// <prerequisite>
54//# Classes you should understand before using this one.
55// <li> MSAntennaGram.l and .y (flex and bison grammar)
56// </prerequisite>
57
58// <synopsis>
59// Global functions are needed to define the input of the flex scanner
60// and to start the bison parser.
61// The input is taken from a string.
62// </synopsis>
63
64// <motivation>
65// It is necessary to be able to give an image expression in ASCII.
66// This can be used in glish.
67// </motivation>
68// <todo asof="$DATE:$">
69//# A List of bugs, limitations, extensions or planned refinements.
70// </todo>
71
72
73// <group name=MSAntennaGramFunctions>
75// Declare the bison parser (is implemented by bison command).
76// It returns a TaQL expression tree.
78 const String& command,
79 Vector<Int>& selectedAnts1,
80 Vector<Int>& selectedAnts2,
81 Matrix<Int>& selectedBaselines) ;
83 const TableExprNode& col1TEN,
84 const TableExprNode& col2TEN,
85 const String& command,
86 Vector<Int>& selectedAnts1,
87 Vector<Int>& selectedAnts2,
88 Matrix<Int>& selectedBaselines) ;
90 TableExprNode& col1TEN,
91 TableExprNode& col2TEN,
92 const String& command,
93 Vector<Int>& selectedAnts1,
94 Vector<Int>& selectedAnts2,
95 Matrix<Int>& selectedBaselines) ;
97 const String& command,
98 Vector<Int>& selectedAnt1,
99 Vector<Int>& selectedAnt2,
100 Matrix<Int>& selectedBaselines);
101
103 Vector<Int>& selectedAnts1,
104 Vector<Int>& selectedAnts2,
105 Matrix<Int>& selectedBaselines);
106 // The yyerror function for the parser.
107 // It throws an exception with the current token.
108 void MSAntennaGramerror (const char*);
109
110 // Give the current position in the string.
111 // This can be used when parse errors occur.
113
114 // Declare the input routine for flex/bison.
115 int msAntennaGramInput (char* buf, int max_size);
116
117 // A function to remove escaped characters.
118 //String msAntennaGramRemoveEscapes (const String& in);
119
120 // A function to remove quotes from a quoted string.
121 //String msAntennaGramRemoveQuotes (const String& in);
122
123 // </group>
124
125} //# NAMESPACE CASACORE - END
126
127#endif
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
int Int
Definition: aipstype.h:50
TableExprNode msAntennaGramParseCommand(MSSelectableTable &msLike, const String &command, Vector< Int > &selectedAnts1, Vector< Int > &selectedAnts2, Matrix< Int > &selectedBaselines)
Declare the bison parser (is implemented by bison command).
int msAntennaGramInput(char *buf, int max_size)
Declare the input routine for flex/bison.
TableExprNode msAntennaGramParseCommand(Table &subTable, TableExprNode &col1TEN, TableExprNode &col2TEN, const String &command, Vector< Int > &selectedAnts1, Vector< Int > &selectedAnts2, Matrix< Int > &selectedBaselines)
Int & msAntennaGramPosition()
Give the current position in the string.
void MSAntennaGramerror(const char *)
The yyerror function for the parser.
TableExprNode msAntennaGramParseCommand(const MeasurementSet *ms, const String &command, Vector< Int > &selectedAnt1, Vector< Int > &selectedAnt2, Matrix< Int > &selectedBaselines)
TableExprNode baseMSAntennaGramParseCommand(MSAntennaParse *parser, const String &command, Vector< Int > &selectedAnts1, Vector< Int > &selectedAnts2, Matrix< Int > &selectedBaselines)
TableExprNode msAntennaGramParseCommand(MSAntennaParse *thisParser, const TableExprNode &col1TEN, const TableExprNode &col2TEN, const String &command, Vector< Int > &selectedAnts1, Vector< Int > &selectedAnts2, Matrix< Int > &selectedBaselines)