bes Updated for version 3.21.1
The Backend Server (BES) is the lower two tiers of the Hyrax data server
FFDods.h
1
2// -*- mode: c++; c-basic-offset:4 -*-
3
4// This file is part of ff_handler a FreeForm API handler for the OPeNDAP
5// DAP2 data server.
6
7// Copyright (c) 2005 OPeNDAP, Inc.
8// Author: James Gallagher <jgallagher@opendap.org>
9//
10// This is free software; you can redistribute it and/or modify it under the
11// terms of the GNU Lesser General Public License as published by the Free
12// Software Foundation; either version 2.1 of the License, or (at your
13// option) any later version.
14//
15// This software is distributed in the hope that it will be useful, but
16// WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
17// or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public
18// License for more details.
19//
20// You should have received a copy of the GNU Lesser General Public
21// License along with this library; if not, write to the Free Software
22// Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
23//
24// You can contact OPeNDAP, Inc. at PO Box 112, Saunderstown, RI. 02874-0112.
25
26
27// (c) COPYRIGHT URI/MIT 1997-98
28// Please read the full copyright statement in the file COPYRIGHT.
29//
30// Authors: reza (Reza Nekovei)
31
32//
33// DODS C++ header file for FreeFrom library.
34//
35// ReZa 6/16/97
36
37#ifndef _ffdods_h
38#define _ffdods_h 1
39
40
41/*
42 * FF_STD_ARGS
43 */
44
45typedef struct struct_ff_std_args FF_STD_ARGS, *FF_STD_ARGS_PTR, **FF_STD_ARGS_HANDLE;
46
48{
49#ifdef FF_CHK_ADDR
50 void *check_address;
51#endif
52 char *input_file; /* string: name of input file */
53 char *input_buffer; /* buffer containing input data */
54 char *input_format_file; /* string: name of input format file */
55 char *input_format_title; /* string: input format title */
56 char *input_format_buffer; /* string: input format description */
57 char *output_file; /* string: name of output file */
58 char *output_buffer; /* buffer to contain output data */
59 char *output_format_file; /* string: name of output format file */
60 char *output_format_title; /* string: output forma title */
61 char *output_format_buffer; /* string: output format description */
62 char *var_file; /* string: name of variable file */
63 char *query_file; /* string: name of query file */
64 unsigned long cache_size; /* integer: default data cacheing size */
65 long records_to_read; /* integer: if negative, file tail */
66
67 char *error_log; /* string: file name to send error messages */
68 BOOLEAN error_prompt;
69
70 /* Checkvar specific option flags */
71 int cv_precision;
72 double cv_missing_data;
73 int cv_maxbins;
74 BOOLEAN cv_maxmin_only;
75
77 {
78 unsigned int set_cv_precision : 1;
79 unsigned int set_cv_missing_data : 1;
80 unsigned int is_stdin_redirected : 1;
81 } user;
82};
83
84/*
85 * FORMAT
86 */
87
88typedef struct struct_ff_format FORMAT, *FORMAT_PTR, **FORMAT_HANDLE;
90{
91#ifdef FF_CHK_ADDR
92 void *check_address; /* assert(format->check_address == format); */
93#endif
94 VARIABLE_LIST variables; /* the DLL of variable structures */
95 char *name; /* title if given in a format file or menu
96 section */
97 char *locus; /* path-name or menu section title of format */
98 FF_TYPES_t type; /* format type, see FFF_LOOKUP format_types */
99 unsigned int num_vars; /* number of variables in format */
100 FF_NDX_t length; /* record length in bytes */
101};
102
103#define FORMAT_NAME_INIT "Format Was Untitled"
104#define FORMAT_LOCUS_INIT "Unknown Origin"
105#define FORMAT_LOCUS_GV_EDIT "GeoVu Format Editor"
106
107/*
108 * FF_BUFSIZE
109 */
110
111typedef struct struct_ff_bufsize FF_BUFSIZE, *FF_BUFSIZE_PTR, **FF_BUFSIZE_HANDLE;
113{
114#ifdef FF_CHK_ADDR
115 void *check_address;
116#endif
117 char HUGE *buffer;
118 unsigned short usage;
119 FF_BSS_t bytes_used;
120 FF_BSS_t total_bytes;
121};
122
123#define DBASK_FORMAT_SUMMARY 3
124
125
126/* Define BIN structures */
127#define FREEFORM_H__
128#include <eval_eqn.h>
129
130
131typedef struct struct_databin
132{
133#ifdef FF_CHK_ADDR
134 void *check_address;
135#endif
136 char *title;
137
138 EQUATION_INFO_PTR eqn_info;
139
140 FF_ARRAY_CONDUIT_LIST array_conduit_list;
141
142 NAME_TABLE_LIST table_list;
143} DATA_BIN, *DATA_BIN_PTR, **DATA_BIN_HANDLE;
144
145extern "C" FF_STD_ARGS_PTR ff_create_std_args(void);
146extern "C" int db_init(struct_ff_std_args *, struct_databin **, int (*)(int));
147extern "C" int db_ask(struct_databin *, int,...);
148
149// $Log: FFDods.h,v $
150// Revision 1.5 2000/10/11 19:37:56 jimg
151// Moved the CVS log entries to the end of files.
152// Changed the definition of the read method to match the dap library.
153// Added exception handling.
154// Added exceptions to the read methods.
155//
156// Revision 1.4 1999/05/27 17:02:22 jimg
157// Merge with alpha-3-0-0
158//
159// Revision 1.3.22.1 1999/05/20 21:39:54 edavis
160// Fix spelling of COPYRIGHT and remove some #if 0 stuff.
161//
162// Revision 1.3 1998/04/21 17:13:45 jimg
163// Fixes for warnings, etc
164//
165// Revision 1.2 1998/04/16 18:11:02 jimg
166// Sequence support added by Reza
167
168#endif