casa  $Rev:20696$
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Defines
Public Member Functions | Static Public Attributes | Private Attributes | Friends
casa::MSParse Class Reference

Class to hold values from an ms grammar parser. More...

#include <MSParse.h>

Inheritance diagram for casa::MSParse:
casa::MSAntennaParse casa::MSArrayParse casa::MSCorrParse casa::MSFieldParse casa::MSObservationParse casa::MSPolnParse casa::MSScanParse casa::MSSpwParse casa::MSStateParse casa::MSTimeParse casa::MSUvDistParse

List of all members.

Public Member Functions

 MSParse ()
 
 

 MSParse (const MSParse &)
 Copy constructor (copy semantics).
 ~MSParse ()
MSParseoperator= (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.
Stringshorthand ()
 Get the shorthand.
MeasurementSetms ()
 Get ms object.
MSSelectableTablemsInterface ()
 Get ms object.
void setMS (MeasurementSet *ms)
void addCondition (TableExprNode &target, TableExprNode &source)

Static Public Attributes

static MeasurementSetms_p
static MSSelectableTablemsInterface_p

Private Attributes

String shorthand_p
MSSelectableTabletempMSInterface_p
 The following exists for the period we make the transition from using MS to using MSSelectableTable.

Friends

AipsIOoperator<< (AipsIO &, const MSParse &)
 Dummy AipsIO routines; they are needed for the List container.
AipsIOoperator>> (AipsIO &, MSParse &)

Detailed Description

Class to hold values from an ms grammar parser.

Intended use:

Internal

Etymology

MSParse is the class used to parse an ms command.

Synopsis

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.

Motivation

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 93 of file MSParse.h.


Constructor & Destructor Documentation

 

Default constructor for List container class.

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.


Member Function Documentation

void casa::MSParse::addCondition ( TableExprNode target,
TableExprNode source 
)

Get ms object.

Referenced by setMS().

Get ms object.

MSParse& casa::MSParse::operator= ( const MSParse )

Assignment (copy semantics).

void casa::MSParse::setMS ( MeasurementSet ms) [inline]

Definition at line 129 of file MSParse.h.

References ms(), and ms_p.

Get the shorthand.

Bool casa::MSParse::test ( const String shortHand) const

Test if shorthand matches.


Friends And Related Function Documentation

AipsIO& operator<< ( AipsIO ,
const MSParse  
) [friend]

Dummy AipsIO routines; they are needed for the List container.

AipsIO& operator>> ( AipsIO ,
MSParse  
) [friend]

Member Data Documentation

Reimplemented in casa::MSTimeParse.

Definition at line 129 of file MSParse.h.

Referenced by setMS().

Definition at line 131 of file MSParse.h.

Definition at line 135 of file MSParse.h.

The following exists for the period we make the transition from using MS to using MSSelectableTable.

Till then, both interfaces have to be supported.

Definition at line 139 of file MSParse.h.


The documentation for this class was generated from the following file: