OPeNDAP Hyrax Back End Server (BES)
Updated for version 3.8.3
|
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <stdlib.h>
#include "config.h"
#include <string>
#include <cstring>
#include "Error.h"
#include "gse.tab.hh"
#include <unistd.h>
Go to the source code of this file.
Typedefs | |
typedef short int | flex_int16_t |
typedef int | flex_int32_t |
typedef signed char | flex_int8_t |
typedef unsigned short int | flex_uint16_t |
typedef unsigned int | flex_uint32_t |
typedef unsigned char | flex_uint8_t |
typedef struct yy_buffer_state * | YY_BUFFER_STATE |
typedef unsigned char | YY_CHAR |
typedef size_t | yy_size_t |
typedef int | yy_state_type |
Functions | |
YY_BUFFER_STATE | gse__create_buffer (FILE *file, int size) |
Allocate and initialize an input buffer state. More... | |
void | gse__delete_buffer (YY_BUFFER_STATE b) |
Destroy the buffer. More... | |
void | gse__flush_buffer (YY_BUFFER_STATE b) |
Discard all buffered characters. More... | |
YY_BUFFER_STATE | gse__scan_buffer (char *base, yy_size_t size) |
Setup the input buffer state to scan directly from a user-specified character buffer. More... | |
YY_BUFFER_STATE | gse__scan_bytes (yyconst char *yybytes, int _yybytes_len) |
Setup the input buffer state to scan the given bytes. More... | |
YY_BUFFER_STATE | gse__scan_string (yyconst char *yystr) |
Setup the input buffer state to scan a string. More... | |
void | gse__switch_to_buffer (YY_BUFFER_STATE new_buffer) |
Switch to a different input buffer. More... | |
void * | gse_alloc (yy_size_t) |
void | gse_delete_buffer (void *buf) |
void | gse_free (void *) |
int | gse_get_debug (void) |
YY_EXTRA_TYPE | gse_get_extra (void) |
FILE * | gse_get_in (void) |
Get the input stream. More... | |
int | gse_get_leng (void) |
Get the length of the current token. More... | |
int | gse_get_lineno (void) |
Get the current line number. More... | |
FILE * | gse_get_out (void) |
Get the output stream. More... | |
char * | gse_get_text (void) |
Get the current token. More... | |
int | gse_lex_destroy (void) |
void | gse_pop_buffer_state (void) |
Removes and deletes the top of the stack, if present. More... | |
void | gse_push_buffer_state (YY_BUFFER_STATE new_buffer) |
Pushes the new state onto the stack. More... | |
void * | gse_realloc (void *, yy_size_t) |
void | gse_restart (FILE *input_file) |
Immediately switch to a different input stream. More... | |
void | gse_set_debug (int debug_flag) |
void | gse_set_extra (YY_EXTRA_TYPE user_defined) |
void | gse_set_in (FILE *in_str) |
Set the input stream. More... | |
void | gse_set_lineno (int line_number) |
Set the current line number. More... | |
void | gse_set_out (FILE *out_str) |
void * | gse_string (const char *str) |
void | gse_switch_to_buffer (void *buf) |
if (!(yy_init)) | |
int | isatty (int) |
while (1) | |
Variables | |
int | gse__flex_debug = 0 |
FILE * | gse_in = (FILE *) 0 |
int | gse_leng |
int | gse_lineno = 1 |
FILE * | gse_out = (FILE *) 0 |
char * | gse_text |
register int | yy_act |
register char * | yy_bp |
register char * | yy_cp |
YY_DECL | |
The main scanner function which does all the work. More... | |
#define BEGIN (yy_start) = 1 + 2 * |
Definition at line 144 of file lex.gse.cc.
Definition at line 653 of file lex.gse.cc.
Referenced by while().
#define EOB_ACT_CONTINUE_SCAN 0 |
Definition at line 179 of file lex.gse.cc.
Referenced by while().
#define EOB_ACT_END_OF_FILE 1 |
Definition at line 180 of file lex.gse.cc.
Referenced by while().
#define EOB_ACT_LAST_MATCH 2 |
Definition at line 181 of file lex.gse.cc.
Referenced by while().
#define FLEX_BETA |
Definition at line 33 of file lex.gse.cc.
#define FLEX_SCANNER |
Definition at line 28 of file lex.gse.cc.
#define FLEXINT_H |
Definition at line 49 of file lex.gse.cc.
#define gse_wrap | ( | n | ) | 1 |
Definition at line 354 of file lex.gse.cc.
Referenced by while().
#define ID_MAX 256 |
Definition at line 544 of file lex.gse.cc.
#define INITIAL 0 |
Definition at line 568 of file lex.gse.cc.
Referenced by while().
#define INT16_MAX (32767) |
Definition at line 92 of file lex.gse.cc.
#define INT16_MIN (-32767-1) |
Definition at line 83 of file lex.gse.cc.
#define INT32_MAX (2147483647) |
Definition at line 95 of file lex.gse.cc.
#define INT32_MIN (-2147483647-1) |
Definition at line 86 of file lex.gse.cc.
#define INT8_MAX (127) |
Definition at line 89 of file lex.gse.cc.
#define INT8_MIN (-128) |
Definition at line 80 of file lex.gse.cc.
#define REJECT reject_used_but_not_detected |
Definition at line 485 of file lex.gse.cc.
#define UINT16_MAX (65535U) |
Definition at line 101 of file lex.gse.cc.
#define UINT32_MAX (4294967295U) |
Definition at line 104 of file lex.gse.cc.
#define UINT8_MAX (255U) |
Definition at line 98 of file lex.gse.cc.
#define unput | ( | c | ) | yyunput( c, (yytext_ptr) ) |
Definition at line 199 of file lex.gse.cc.
#define YY_AT_BOL | ( | ) | (YY_CURRENT_BUFFER_LVALUE->yy_at_bol) |
Definition at line 350 of file lex.gse.cc.
#define YY_BREAK break; |
Definition at line 732 of file lex.gse.cc.
Referenced by while().
#define YY_BUF_SIZE 16384 |
Definition at line 163 of file lex.gse.cc.
Referenced by gse_restart(), and if().
#define YY_BUFFER_EOF_PENDING 2 |
Definition at line 266 of file lex.gse.cc.
#define YY_BUFFER_NEW 0 |
Definition at line 254 of file lex.gse.cc.
Referenced by gse__flush_buffer(), gse__scan_buffer(), and while().
#define YY_BUFFER_NORMAL 1 |
Definition at line 255 of file lex.gse.cc.
Referenced by while().
#define yy_create_buffer gse__create_buffer |
Definition at line 9 of file lex.gse.cc.
#define YY_CURRENT_BUFFER |
Definition at line 282 of file lex.gse.cc.
Referenced by gse__delete_buffer(), gse__flush_buffer(), gse__switch_to_buffer(), gse_lex_destroy(), gse_pop_buffer_state(), gse_push_buffer_state(), gse_restart(), and if().
#define YY_CURRENT_BUFFER_LVALUE (yy_buffer_stack)[(yy_buffer_stack_top)] |
Definition at line 289 of file lex.gse.cc.
Referenced by gse__delete_buffer(), gse__switch_to_buffer(), gse_lex_destroy(), gse_pop_buffer_state(), gse_push_buffer_state(), gse_restart(), if(), and while().
Definition at line 543 of file lex.gse.cc.
#define yy_delete_buffer gse__delete_buffer |
Definition at line 10 of file lex.gse.cc.
#define YY_DO_BEFORE_ACTION |
#define YY_END_OF_BUFFER 11 |
Definition at line 386 of file lex.gse.cc.
Referenced by while().
#define YY_END_OF_BUFFER_CHAR 0 |
Definition at line 159 of file lex.gse.cc.
Referenced by gse__flush_buffer(), gse__scan_buffer(), and gse__scan_bytes().
#define YY_EXIT_FAILURE 2 |
Definition at line 1639 of file lex.gse.cc.
#define YY_EXTRA_TYPE void * |
Definition at line 579 of file lex.gse.cc.
#define YY_FATAL_ERROR | ( | msg | ) |
Definition at line 549 of file lex.gse.cc.
Referenced by gse__create_buffer(), gse__scan_buffer(), gse__scan_bytes(), and while().
#define yy_flex_debug gse__flex_debug |
Definition at line 11 of file lex.gse.cc.
#define YY_FLEX_MAJOR_VERSION 2 |
Definition at line 29 of file lex.gse.cc.
#define YY_FLEX_MINOR_VERSION 5 |
Definition at line 30 of file lex.gse.cc.
#define YY_FLEX_SUBMINOR_VERSION 35 |
Definition at line 31 of file lex.gse.cc.
#define yy_flush_buffer gse__flush_buffer |
Definition at line 13 of file lex.gse.cc.
#define YY_FLUSH_BUFFER gse__flush_buffer(YY_CURRENT_BUFFER ) |
Definition at line 318 of file lex.gse.cc.
#define yy_init_buffer gse__init_buffer |
Definition at line 12 of file lex.gse.cc.
#define YY_INPUT | ( | buf, | |
result, | |||
max_size | |||
) |
Definition at line 660 of file lex.gse.cc.
#define YY_INT_ALIGNED short int |
Definition at line 5 of file lex.gse.cc.
#define YY_LESS_LINENO | ( | n | ) |
Definition at line 183 of file lex.gse.cc.
#define yy_load_buffer_state gse__load_buffer_state |
Definition at line 14 of file lex.gse.cc.
#define YY_MORE_ADJ 0 |
Definition at line 487 of file lex.gse.cc.
Referenced by while().
#define yy_new_buffer gse__create_buffer |
Definition at line 328 of file lex.gse.cc.
#define YY_NEW_FILE gse_restart(gse_in ) |
Definition at line 157 of file lex.gse.cc.
Referenced by while().
#define YY_NO_INPUT 1 |
Definition at line 546 of file lex.gse.cc.
#define YY_NO_UNPUT 1 |
Definition at line 545 of file lex.gse.cc.
#define YY_NULL 0 |
Definition at line 131 of file lex.gse.cc.
#define YY_NUM_RULES 10 |
Definition at line 385 of file lex.gse.cc.
#define YY_PROTO | ( | proto | ) | proto |
Definition at line 540 of file lex.gse.cc.
#define YY_READ_BUF_SIZE 8192 |
Definition at line 645 of file lex.gse.cc.
#define YY_RESTORE_YY_MORE_OFFSET |
Definition at line 488 of file lex.gse.cc.
Referenced by while().
#define YY_RULE_SETUP YY_USER_ACTION |
Definition at line 735 of file lex.gse.cc.
Referenced by while().
#define YY_SC_TO_UI | ( | c | ) | ((unsigned int) (unsigned char) c) |
Definition at line 138 of file lex.gse.cc.
Referenced by while().
#define yy_set_bol | ( | at_bol | ) |
Definition at line 340 of file lex.gse.cc.
#define yy_set_interactive | ( | is_interactive | ) |
Definition at line 330 of file lex.gse.cc.
#define YY_SKIP_YYWRAP |
Definition at line 355 of file lex.gse.cc.
#define YY_START (((yy_start) - 1) / 2) |
Definition at line 150 of file lex.gse.cc.
Referenced by while().
#define YY_START_STACK_INCR 25 |
Definition at line 702 of file lex.gse.cc.
#define YY_STATE_BUF_SIZE ((YY_BUF_SIZE + 2) * sizeof(yy_state_type)) |
Definition at line 168 of file lex.gse.cc.
#define YY_STATE_EOF | ( | state | ) | (YY_END_OF_BUFFER + state + 1) |
Definition at line 154 of file lex.gse.cc.
Referenced by while().
#define YY_STRUCT_YY_BUFFER_STATE |
Definition at line 207 of file lex.gse.cc.
#define yy_switch_to_buffer gse__switch_to_buffer |
Definition at line 15 of file lex.gse.cc.
#define YY_TYPEDEF_YY_BUFFER_STATE |
Definition at line 171 of file lex.gse.cc.
#define YY_TYPEDEF_YY_SIZE_T |
Definition at line 202 of file lex.gse.cc.
#define YY_USER_ACTION |
Definition at line 727 of file lex.gse.cc.
#define yyalloc gse_alloc |
Definition at line 24 of file lex.gse.cc.
Referenced by if().
#define yyconst |
Definition at line 127 of file lex.gse.cc.
#define yyfree gse_free |
Definition at line 26 of file lex.gse.cc.
#define yyin gse_in |
Definition at line 16 of file lex.gse.cc.
#define yyleng gse_leng |
Definition at line 17 of file lex.gse.cc.
#define yyless | ( | n | ) |
Definition at line 1651 of file lex.gse.cc.
#define yyless | ( | n | ) |
Definition at line 1651 of file lex.gse.cc.
#define yylex gse_lex |
Definition at line 18 of file lex.gse.cc.
#define yylineno gse_lineno |
Definition at line 19 of file lex.gse.cc.
#define yymore | ( | ) | yymore_used_but_not_detected |
Definition at line 486 of file lex.gse.cc.
#define yyout gse_out |
Definition at line 20 of file lex.gse.cc.
#define yyrealloc gse_realloc |
Definition at line 25 of file lex.gse.cc.
#define yyrestart gse_restart |
Definition at line 21 of file lex.gse.cc.
#define YYSTATE YY_START |
Definition at line 151 of file lex.gse.cc.
#define YYTABLES_NAME "yytables" |
Definition at line 1841 of file lex.gse.cc.
#define yyterminate | ( | ) | return YY_NULL |
Definition at line 697 of file lex.gse.cc.
Referenced by while().
#define yytext gse_text |
Definition at line 22 of file lex.gse.cc.
#define yytext_ptr gse_text |
Definition at line 368 of file lex.gse.cc.
Referenced by while().
#define yywrap gse_wrap |
Definition at line 23 of file lex.gse.cc.
typedef short int flex_int16_t |
Definition at line 71 of file lex.gse.cc.
typedef int flex_int32_t |
Definition at line 72 of file lex.gse.cc.
typedef signed char flex_int8_t |
Definition at line 70 of file lex.gse.cc.
typedef unsigned short int flex_uint16_t |
Definition at line 74 of file lex.gse.cc.
typedef unsigned int flex_uint32_t |
Definition at line 75 of file lex.gse.cc.
typedef unsigned char flex_uint8_t |
Definition at line 73 of file lex.gse.cc.
typedef struct yy_buffer_state* YY_BUFFER_STATE |
Definition at line 172 of file lex.gse.cc.
typedef unsigned char YY_CHAR |
Definition at line 357 of file lex.gse.cc.
typedef size_t yy_size_t |
Definition at line 203 of file lex.gse.cc.
typedef int yy_state_type |
Definition at line 361 of file lex.gse.cc.
YY_BUFFER_STATE gse__create_buffer | ( | FILE * | file, |
int | size | ||
) |
Allocate and initialize an input buffer state.
file | A readable stream. |
size | The character buffer size in bytes. When in doubt, use YY_BUF_SIZE . |
Definition at line 1352 of file lex.gse.cc.
References gse_alloc(), and YY_FATAL_ERROR.
Referenced by gse_restart(), and if().
void gse__delete_buffer | ( | YY_BUFFER_STATE | b | ) |
Destroy the buffer.
b | a buffer created with gse__create_buffer() |
Definition at line 1380 of file lex.gse.cc.
References gse_free(), YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
Referenced by gse_delete_buffer(), gse_lex_destroy(), and gse_pop_buffer_state().
void gse__flush_buffer | ( | YY_BUFFER_STATE | b | ) |
Discard all buffered characters.
On the next scan, YY_INPUT will be called.
b | the buffer state to be flushed, usually YY_CURRENT_BUFFER . |
Definition at line 1431 of file lex.gse.cc.
References YY_BUFFER_NEW, YY_CURRENT_BUFFER, and YY_END_OF_BUFFER_CHAR.
YY_BUFFER_STATE gse__scan_buffer | ( | char * | base, |
yy_size_t | size | ||
) |
Setup the input buffer state to scan directly from a user-specified character buffer.
base | the character buffer |
size | the size in bytes of the character buffer |
Definition at line 1558 of file lex.gse.cc.
References gse__switch_to_buffer(), gse_alloc(), YY_BUFFER_NEW, YY_END_OF_BUFFER_CHAR, and YY_FATAL_ERROR.
Referenced by gse__scan_bytes().
YY_BUFFER_STATE gse__scan_bytes | ( | yyconst char * | yybytes, |
int | _yybytes_len | ||
) |
Setup the input buffer state to scan the given bytes.
The next call to gse_lex() will scan from a copy of bytes.
bytes | the byte buffer to scan |
len | the number of bytes in the buffer pointed to by bytes. |
Definition at line 1608 of file lex.gse.cc.
References gse__scan_buffer(), gse_alloc(), YY_END_OF_BUFFER_CHAR, and YY_FATAL_ERROR.
Referenced by gse__scan_string().
YY_BUFFER_STATE gse__scan_string | ( | yyconst char * | yystr | ) |
Setup the input buffer state to scan a string.
The next call to gse_lex() will scan from a copy of str.
yystr | a NUL-terminated string to scan |
Definition at line 1595 of file lex.gse.cc.
References gse__scan_bytes().
Referenced by gse_string().
void gse__switch_to_buffer | ( | YY_BUFFER_STATE | new_buffer | ) |
Switch to a different input buffer.
new_buffer | The new input buffer. |
Definition at line 1307 of file lex.gse.cc.
References YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
Referenced by gse__scan_buffer(), and gse_switch_to_buffer().
void * gse_alloc | ( | yy_size_t | size | ) |
Definition at line 1819 of file lex.gse.cc.
Referenced by gse__create_buffer(), gse__scan_buffer(), and gse__scan_bytes().
void gse_delete_buffer | ( | void * | buf | ) |
Definition at line 1866 of file lex.gse.cc.
References gse__delete_buffer().
Referenced by libdap::parse_gse_expression().
void gse_free | ( | void * | ptr | ) |
Definition at line 1836 of file lex.gse.cc.
Referenced by gse__delete_buffer(), and gse_lex_destroy().
int gse_get_debug | ( | void | ) |
Definition at line 1735 of file lex.gse.cc.
References gse__flex_debug.
YY_EXTRA_TYPE gse_get_extra | ( | void | ) |
FILE * gse_get_in | ( | void | ) |
int gse_get_leng | ( | void | ) |
Get the length of the current token.
Definition at line 1695 of file lex.gse.cc.
References gse_leng.
int gse_get_lineno | ( | void | ) |
FILE * gse_get_out | ( | void | ) |
char * gse_get_text | ( | void | ) |
int gse_lex_destroy | ( | void | ) |
Definition at line 1774 of file lex.gse.cc.
References gse__delete_buffer(), gse_free(), gse_pop_buffer_state(), YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
void gse_pop_buffer_state | ( | void | ) |
Removes and deletes the top of the stack, if present.
The next element becomes the new top.
Definition at line 1490 of file lex.gse.cc.
References gse__delete_buffer(), YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
Referenced by gse_lex_destroy().
void gse_push_buffer_state | ( | YY_BUFFER_STATE | new_buffer | ) |
Pushes the new state onto the stack.
The new state becomes the current state. This function will allocate the stack if necessary.
new_buffer | The new state. |
Definition at line 1460 of file lex.gse.cc.
References YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
void * gse_realloc | ( | void * | ptr, |
yy_size_t | size | ||
) |
Definition at line 1824 of file lex.gse.cc.
void gse_restart | ( | FILE * | input_file | ) |
Immediately switch to a different input stream.
input_file | A readable stream. |
INITIAL
. Definition at line 1290 of file lex.gse.cc.
References gse__create_buffer(), gse_in, YY_BUF_SIZE, YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
Referenced by libdap::parse_gse_expression().
void gse_set_debug | ( | int | debug_flag | ) |
Definition at line 1740 of file lex.gse.cc.
void gse_set_extra | ( | YY_EXTRA_TYPE | user_defined | ) |
void gse_set_in | ( | FILE * | in_str | ) |
Set the input stream.
This does not discard the current input buffer.
in_str | A readable stream. |
Definition at line 1725 of file lex.gse.cc.
References gse_in.
void gse_set_lineno | ( | int | line_number | ) |
void gse_set_out | ( | FILE * | out_str | ) |
Definition at line 1730 of file lex.gse.cc.
References gse_out.
void* gse_string | ( | const char * | str | ) |
Definition at line 1854 of file lex.gse.cc.
References gse__scan_string().
Referenced by libdap::parse_gse_expression().
void gse_switch_to_buffer | ( | void * | buf | ) |
Definition at line 1860 of file lex.gse.cc.
References gse__switch_to_buffer().
if | ( | ! | yy_init | ) |
Definition at line 751 of file lex.gse.cc.
References gse__create_buffer(), gse_in, gse_out, YY_BUF_SIZE, YY_CURRENT_BUFFER, and YY_CURRENT_BUFFER_LVALUE.
int isatty | ( | int | ) |
while | ( | 1 | ) |
Definition at line 777 of file lex.gse.cc.
References ECHO, EOB_ACT_CONTINUE_SCAN, EOB_ACT_END_OF_FILE, EOB_ACT_LAST_MATCH, gse_in, gse_wrap, INITIAL, SCAN_EQUAL, SCAN_FLOAT, SCAN_GREATER, SCAN_GREATER_EQL, SCAN_INT, SCAN_LESS, SCAN_LESS_EQL, SCAN_NOT_EQUAL, SCAN_WORD, YY_BREAK, YY_BUFFER_NEW, YY_BUFFER_NORMAL, yy_cp, YY_CURRENT_BUFFER_LVALUE, YY_DO_BEFORE_ACTION, YY_END_OF_BUFFER, YY_FATAL_ERROR, YY_MORE_ADJ, YY_NEW_FILE, YY_RESTORE_YY_MORE_OFFSET, YY_RULE_SETUP, YY_SC_TO_UI, YY_START, YY_STATE_EOF, yyterminate, and yytext_ptr.
int gse__flex_debug = 0 |
Definition at line 480 of file lex.gse.cc.
Referenced by gse_get_debug().
FILE * gse_in = (FILE *) 0 |
Definition at line 359 of file lex.gse.cc.
Referenced by gse_get_in(), gse_restart(), gse_set_in(), if(), and while().
int gse_leng |
Definition at line 294 of file lex.gse.cc.
Referenced by gse_get_leng().
int gse_lineno = 1 |
Definition at line 365 of file lex.gse.cc.
Referenced by gse_get_lineno().
FILE * gse_out = (FILE *) 0 |
Definition at line 359 of file lex.gse.cc.
Referenced by gse_get_out(), gse_set_out(), and if().
char * gse_text |
Definition at line 489 of file lex.gse.cc.
Referenced by gse_get_text().
register int yy_act |
Definition at line 744 of file lex.gse.cc.
register char * yy_bp |
Definition at line 743 of file lex.gse.cc.
register char* yy_cp |
Definition at line 743 of file lex.gse.cc.
Referenced by while().
YY_DECL |
The main scanner function which does all the work.
Definition at line 741 of file lex.gse.cc.