casa
5.7.0-16
|
Class to hold values from field grammar parser. More...
#include <MSSpwParse.h>
Public Member Functions | |
MSSpwParse () | |
Default constructor. More... | |
MSSpwParse (const MeasurementSet *ms) | |
~MSSpwParse() {if (node_p) delete node_p;node_p=0x0;}; More... | |
MSSpwParse (const MSSpectralWindow &spwSubTable, const MSDataDescription &ddSubTable, const TableExprNode &columnAsTEN) | |
~MSSpwParse () | |
const TableExprNode * | selectSpwIdsFromIDList (const Vector< Int > &spwIds, const Bool addTen=True, const Bool addIDs=True) |
const TableExprNode * | selectSpwIdsFromFreqList (const Vector< Float > &spwIds, const Float factor) |
void | selectChannelsFromIDList (Vector< Int > &spwIds, Vector< Int > &chanIDList, Int nFSpec) |
void | selectChannelsFromDefaultList (Vector< Int > &spwIds, Vector< Int > &chanDefaultList) |
const TableExprNode * | endOfCeremony (const TableExprNode &ten) |
MSSpectralWindow & | subTable () |
Public Member Functions inherited from casacore::MSParse | |
MSParse () | |
Default constructor for List container class. More... | |
MSParse (const MSParse &) | |
Copy constructor (copy semantics). More... | |
~MSParse () | |
MSParse & | operator= (const MSParse &) |
Assignment (copy semantics). More... | |
MSParse (const MeasurementSet *ms, const String &shorthand) | |
Associate the ms and the shorthand. More... | |
MSParse (const MSSelectableTable *ms, const String &shorthand) | |
Associate the ms and the shorthand. More... | |
Bool | test (const String &shortHand) const |
Test if shorthand matches. More... | |
String & | shorthand () |
Get the shorthand. More... | |
MeasurementSet * | ms () |
Get ms object. More... | |
MSSelectableTable * | msInterface () |
Get ms object. More... | |
void | setMS (MeasurementSet *ms) |
void | setMSInterface (MSSelectableTable *msI) |
void | addCondition (TableExprNode &target, TableExprNode &source) |
Static Public Member Functions | |
static const TableExprNode * | node () |
const TableExprNode *selectSpwOrSource(const String& fieldName); More... | |
static Vector< Int > | selectedDDIDs () |
static Vector< Int > | selectedIDs () |
static Matrix< Int > | selectedChanIDs () |
static void | reset () |
static void | cleanupNode () |
static void | cleanupErrorHandler () |
static void | cleanup () |
Static Public Attributes | |
static MSSpwParse * | thisMSSParser |
static CountedPtr < MSSelectionErrorHandler > | thisMSSpwErrorHandler |
Static Public Attributes inherited from casacore::MSParse | |
static MeasurementSet * | ms_p |
static MSSelectableTable * | msInterface_p |
Private Attributes | |
MSSpectralWindow | spwSubTable_p |
MSDataDescription | ddSubTable_p |
Static Private Attributes | |
static TableExprNode * | node_p |
static Vector< Int > | idList |
static Vector< Int > | ddidList |
static Matrix< Int > | chanList |
static TableExprNode | columnAsTEN_p |
Class to hold values from field grammar parser.
Internal
MSSpwParse is the class used to parse a spectral window selection command.
MSSpwParse is used by the parser of spectral window (Spw) sub-expression statements. The parser is written in Bison and Flex in files MSSpwGram.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 MSSpwParse only contains information about a table used in the table command. Global variables (like a list and a vector) are used in MSSpwParse.cc to hold further information.
Global functions are used to operate on the information. The main function is the global function msSpwCommand. 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.
Definition at line 88 of file MSSpwParse.h.
casacore::MSSpwParse::MSSpwParse | ( | ) |
Default constructor.
casacore::MSSpwParse::MSSpwParse | ( | const MeasurementSet * | ms | ) |
~MSSpwParse() {if (node_p) delete node_p;node_p=0x0;};
Associate the ms and the shorthand.
casacore::MSSpwParse::MSSpwParse | ( | const MSSpectralWindow & | spwSubTable, |
const MSDataDescription & | ddSubTable, | ||
const TableExprNode & | columnAsTEN | ||
) |
|
inline |
Definition at line 99 of file MSSpwParse.h.
References columnAsTEN_p.
|
inlinestatic |
Definition at line 126 of file MSSpwParse.h.
References cleanupErrorHandler(), and cleanupNode().
|
inlinestatic |
Definition at line 125 of file MSSpwParse.h.
References thisMSSpwErrorHandler.
Referenced by cleanup().
|
inlinestatic |
const TableExprNode* casacore::MSSpwParse::endOfCeremony | ( | const TableExprNode & | ten | ) |
|
static |
const TableExprNode *selectSpwOrSource(const String& fieldName);
Get table expression node object.
|
inlinestatic |
Definition at line 123 of file MSSpwParse.h.
References chanList, ddidList, idList, casacore::Matrix< T >::resize(), and casacore::Vector< T >::resize().
void casacore::MSSpwParse::selectChannelsFromDefaultList | ( | Vector< Int > & | spwIds, |
Vector< Int > & | chanDefaultList | ||
) |
void casacore::MSSpwParse::selectChannelsFromIDList | ( | Vector< Int > & | spwIds, |
Vector< Int > & | chanIDList, | ||
Int | nFSpec | ||
) |
Definition at line 122 of file MSSpwParse.h.
References chanList.
Definition at line 120 of file MSSpwParse.h.
References ddidList.
Definition at line 121 of file MSSpwParse.h.
References idList.
const TableExprNode* casacore::MSSpwParse::selectSpwIdsFromFreqList | ( | const Vector< Float > & | spwIds, |
const Float | factor | ||
) |
const TableExprNode* casacore::MSSpwParse::selectSpwIdsFromIDList | ( | const Vector< Int > & | spwIds, |
const Bool | addTen = True , |
||
const Bool | addIDs = True |
||
) |
|
inline |
Definition at line 128 of file MSSpwParse.h.
References spwSubTable_p.
Definition at line 132 of file MSSpwParse.h.
Referenced by reset(), and selectedChanIDs().
|
staticprivate |
Definition at line 135 of file MSSpwParse.h.
Referenced by ~MSSpwParse().
Definition at line 131 of file MSSpwParse.h.
Referenced by reset(), and selectedDDIDs().
|
private |
Definition at line 134 of file MSSpwParse.h.
Definition at line 131 of file MSSpwParse.h.
Referenced by reset(), and selectedIDs().
|
staticprivate |
Definition at line 130 of file MSSpwParse.h.
Referenced by cleanupNode().
|
private |
Definition at line 133 of file MSSpwParse.h.
Referenced by subTable().
|
static |
Definition at line 118 of file MSSpwParse.h.
|
static |
Definition at line 119 of file MSSpwParse.h.
Referenced by cleanupErrorHandler().