Loading...
Searching...
No Matches
casacore::TableGram_global_functions_TableGramFunctions Struct Reference
tables package (libcasa_tables) » TaQL_module » TaQL_module_internal_classes

More...

`#include <TableGram.h>`

## Public Member Functions

int | tableGramParseCommand (const String &command)
| Declare the bison parser (is implemented by bison command).
void | TableGramerror (const char *)
| The yyerror function for the parser.
Int & | tableGramPosition ()
| Give the current position in the string.
int | tableGramInput (char *buf, int max_size)
| Declare the input routine for flex/bison.
String | tableGramRemoveEscapes (const String &in)
| A function to remove escape characters.
String | tableGramRemoveEscapesQuotes (const String &in)
| A function to remove escape characters and quotes.
String | tableGramRemoveQuotes (const String &in)
| A function to remove quotes from a quoted string.
MVTime | tableGramParseDateTime (const String &in)
| A function to parse a date/time string.
Double | tableGramParseTime (const String &in)
| A function to parse a time/position string.

## Detailed Description

Global functions for flex/bison scanner/parser for TableGram

### Intended use:

Internal

### Review Status

Reviewed By:
  UNKNOWN
Date Reviewed:
  before2004/08/25
Test programs:
  tTableGram

### Prerequisite

- TableGram.l and.y (flex and bison grammar)

### Synopsis

Global functions are needed to define the input of the flex scanner and to start the bison parser. The input is taken from a string.

### Motivation

It is necessary to be able to give a table select 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 70 of file TableGram.h.

## Member Function Documentation

## TableGramerror()

void casacore::TableGram_global_functions_TableGramFunctions::TableGramerror | ( | const char * |  | ) |

The yyerror function for the parser.

It throws an exception with the current token.

## tableGramInput()

int casacore::TableGram_global_functions_TableGramFunctions::tableGramInput | ( | char * | buf,
|  | int | max_size )

Declare the input routine for flex/bison.

## tableGramParseCommand()

int casacore::TableGram_global_functions_TableGramFunctions::tableGramParseCommand | ( | const String & | command | ) |

Declare the bison parser (is implemented by bison command).

## tableGramParseDateTime()

MVTime casacore::TableGram_global_functions_TableGramFunctions::tableGramParseDateTime | ( | const String & | in | ) |

A function to parse a date/time string.

## tableGramParseTime()

Double casacore::TableGram_global_functions_TableGramFunctions::tableGramParseTime | ( | const String & | in | ) |

A function to parse a time/position string.

The value is returned in radians.

## tableGramPosition()

Int & casacore::TableGram_global_functions_TableGramFunctions::tableGramPosition | ( |  | ) |

Give the current position in the string.

This can be used when parse errors occur.

## tableGramRemoveEscapes()

String casacore::TableGram_global_functions_TableGramFunctions::tableGramRemoveEscapes | ( | const String & | in | ) |

A function to remove escape characters.

## tableGramRemoveEscapesQuotes()

String casacore::TableGram_global_functions_TableGramFunctions::tableGramRemoveEscapesQuotes | ( | const String & | in | ) |

A function to remove escape characters and quotes.

## tableGramRemoveQuotes()

String casacore::TableGram_global_functions_TableGramFunctions::tableGramRemoveQuotes | ( | const String & | in | ) |

A function to remove quotes from a quoted string.

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

- tables/TaQL/TableGram.h