casa
$Rev:20696$
|
Class to hold values from an ms grammar parser. More...
#include <MSParse.h>
Public Member Functions | |
MSParse () | |
MSParse (const MSParse &) | |
Copy constructor (copy semantics). | |
~MSParse () | |
MSParse & | operator= (const MSParse &) |
Assignment (copy semantics). | |
MSParse (const MeasurementSet *ms, const String &shorthand) | |
Associate the ms and the shorthand. | |
MSParse (const MSSelectableTable *ms, const String &shorthand) | |
Associate the ms and the shorthand. | |
Bool | test (const String &shortHand) const |
Test if shorthand matches. | |
String & | shorthand () |
Get the shorthand. | |
MeasurementSet * | ms () |
Get ms object. | |
MSSelectableTable * | msInterface () |
Get ms object. | |
void | setMS (MeasurementSet *ms) |
void | addCondition (TableExprNode &target, TableExprNode &source) |
Static Public Attributes | |
static MeasurementSet * | ms_p |
static MSSelectableTable * | msInterface_p |
Private Attributes | |
String | shorthand_p |
MSSelectableTable * | tempMSInterface_p |
The following exists for the period we make the transition from using MS to using MSSelectableTable. | |
Friends | |
AipsIO & | operator<< (AipsIO &, const MSParse &) |
Dummy AipsIO routines; they are needed for the List container. | |
AipsIO & | operator>> (AipsIO &, MSParse &) |
Class to hold values from an ms grammar parser.
Internal
MSParse is the class used to parse an ms command.
MSParse is used by the parser of an ms sub-expression statements. The parser is written in Bison and Flex in files MSXXXGram.y and .l. The statements in there use the routines in this file to act upon a reduced rule. Since multiple tables can be given (with a shorthand), the table names are stored in a list. The variable names can be qualified by the table name and will be looked up in the appropriate table.
The class MSParse only contains information about an ms used in the ms command. Global variables (like a list and a vector) are used in MSParse.cc to hold further information.
Global functions are used to operate on the information. The main function is the global function msXXXCommand. It executes the given STaQL command and returns the resulting ms. This is, in fact, the only function to be used by a user.
It is necessary to be able to give a ms command in ASCII. This can be used in a CLI or in the table browser to get a subset of a table or to sort a table.
Default constructor for List container class.
casa::MSParse::MSParse | ( | const MSParse & | ) |
Copy constructor (copy semantics).
casa::MSParse::MSParse | ( | const MeasurementSet * | ms, |
const String & | shorthand | ||
) |
Associate the ms and the shorthand.
casa::MSParse::MSParse | ( | const MSSelectableTable * | ms, |
const String & | shorthand | ||
) |
Associate the ms and the shorthand.
void casa::MSParse::addCondition | ( | TableExprNode & | target, |
TableExprNode & | source | ||
) |
Get ms object.
Referenced by setMS().
Get ms object.
void casa::MSParse::setMS | ( | MeasurementSet * | ms | ) | [inline] |
Get the shorthand.
Bool casa::MSParse::test | ( | const String & | shortHand | ) | const |
Test if shorthand matches.
MeasurementSet* casa::MSParse::ms_p [static] |
Reimplemented in casa::MSTimeParse.
Definition at line 129 of file MSParse.h.
Referenced by setMS().
String casa::MSParse::shorthand_p [private] |
The following exists for the period we make the transition from using MS to using MSSelectableTable.
Till then, both interfaces have to be supported.