/[LeafOK_CVS]/pvpgn-1.7.4/src/bnetd/storage_sql.h
ViewVC logotype

Annotation of /pvpgn-1.7.4/src/bnetd/storage_sql.h

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.1.1.1 - (hide annotations) (vendor branch)
Tue Jun 6 03:41:37 2006 UTC (19 years, 9 months ago) by sysadm
Branch: GNU, MAIN
CVS Tags: pvpgn_1-7-4-0_MIL, arelease, HEAD
Changes since 1.1: +0 -0 lines
Content type: text/x-chdr
no message

1 sysadm 1.1 /*
2     * Copyright (C) 2002,2003 Mihai RUSU (dizzy@rdsnet.ro)
3     *
4     * This program is free software; you can redistribute it and/or
5     * modify it under the terms of the GNU General Public License
6     * as published by the Free Software Foundation; either version 2
7     * of the License, or (at your option) any later version.
8     *
9     * This program is distributed in the hope that it will be useful,
10     * but WITHOUT ANY WARRANTY; without even the implied warranty of
11     * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12     * GNU General Public License for more details.
13     *
14     * You should have received a copy of the GNU General Public License
15     * along with this program; if not, write to the Free Software
16     * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
17     */
18    
19     #ifndef INCLUDED_STORAGE_SQL_TYPES
20     #define INCLUDED_STORAGE_SQL_TYPES
21    
22     typedef unsigned int t_sql_info;
23    
24     /* mysql and pgsql at least return a pointer to something */
25     #define t_sql_res void
26    
27     typedef char * t_sql_row;
28    
29     typedef char * t_sql_field;
30    
31     typedef struct {
32     int (*init)(const char *host, const char *port, const char *socket, const char *name, const char *user, const char *pass);
33     int (*close)(void);
34     t_sql_res * (*query_res)(const char *);
35     int (*query)(const char *);
36     t_sql_row * (*fetch_row)(t_sql_res *);
37     void (*free_result)(t_sql_res *);
38     unsigned int (*num_rows)(t_sql_res *);
39     unsigned int (*num_fields)(t_sql_res *);
40     unsigned int (*affected_rows)(void);
41     t_sql_field * (*fetch_fields)(t_sql_res *);
42     int (*free_fields)(t_sql_field *);
43     void (*escape_string)(char *, const char *, int);
44     } t_sql_engine;
45    
46     #endif /* INCLUDED_STORAGE_SQL_TYPES */
47    
48     #ifndef JUST_NEED_TYPES
49     #ifndef INCLUDED_STORAGE_SQL_PROTOS
50     #define INCLUDED_STORAGE_SQL_PROTOS
51    
52     #include "storage.h"
53    
54     extern t_storage storage_sql;
55    
56     #endif /* INCLUDED_STORAGE_SQL_PROTOS */
57     #endif /* JUST_NEED_TYPES */

webmaster@leafok.com
ViewVC Help
Powered by ViewVC 1.3.0-beta1