Develop and Download Open Source Software

Browse CVS Repository

Contents of /xoonips/AL/common.h

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.18 - (show annotations) (download) (as text)
Mon May 23 07:58:26 2005 UTC (18 years, 9 months ago) by tani
Branch: MAIN
CVS Tags: AL_PORTING, MergePnt_20051116, REL20051226, XOONIPS_RC1, REL20060323, tag20070307current, MergePnt_20051220, tag20061130, merge_to_20060605, tag20070307, REL20060213, merge_to_20060411, HEAD
Branch point for: XOONIPS_STABLE_32, XOONIPS_STABLE, XOONIPS_STABLE_3, XOONIPS_STABLE_2
Changes since 1.17: +2 -1 lines
File MIME type: text/x-chdr
RES_GROUPNAME_ALREADY_EXISTSの定義を追加.

1 /*
2 * --------------------------------------------------------------------------
3 * XooNiPs Xoops modules for Neuroinformatics Platforms
4 * Copyright (C) 2005 RIKEN, Japan. All rights reserved.
5 * http://sourceforge.jp/projects/xoonips/
6 * --------------------------------------------------------------------------
7 * This program is free software; you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation; either version 2
10 * of the License, or (at your option) any later version.
11 *
12 * This program is distributed in the hope that it will be useful,
13 * but WITHOUT ANY WARRANTY; without even the implied warranty of
14 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15 * GNU General Public License for more details.
16 *
17 * You should have received a copy of the GNU General Public License
18 * along with this program; if not, write to the Free Software
19 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
20 * --------------------------------------------------------------------------
21 *
22 * $Revision: 1.17 $
23 */
24 #if !defined( COMMON_H )
25 #define COMMON_H
26
27
28 #if defined(__BORLANDC__)
29 #define PROTOTYPES 1
30 #include "md5/global.h"
31 #ifdef __cplusplus
32 extern "C" {
33 #endif
34 #include "md5/md5.h"
35 #ifdef __cplusplus
36 }
37 #endif
38
39 #define MD5_Init MD5Init
40 #define MD5_Update MD5Update
41 #define MD5_Final MD5Final
42
43 #define snprintf _snprintf
44
45 #else
46 #include <openssl/md5.h>
47 #endif
48 #include<string>
49
50 using namespace std;
51 typedef enum {
52 RES_OK = 0,
53 RES_ERROR,
54 RES_DB_NOT_INITIALIZED,
55 RES_LOGIN_FAILURE,
56 RES_NO_SUCH_SESSION,
57 RES_NO_SUCH_USER,
58 RES_NO_SUCH_GROUP,
59 RES_DB_QUERY_ERROR,
60 RES_DB_CONNECT_ERROR,
61 RES_DB_INITIALIZE_ERROR,
62 RES_NO_SUCH_ITEM,
63 RES_NO_WRITE_ACCESS_RIGHT,
64 RES_NO_READ_ACCESS_RIGHT,
65 RES_GROUPNAME_ALREADY_EXISTS,
66
67 RES_PHP_NONREF=1000
68 } result_t;
69
70 typedef enum {
71 DBTYPE_MYSQL = 1,
72 DBTYPE_SQLITE = 2
73 } dbtype_t;
74
75 char* str_dup( const char* );
76 char* setValue( char** , const char* );
77 string intToString( int i );
78 string unsignedIntToString( unsigned int i );
79 string doubleToString( double d );
80
81 #define MD5_DIGEST_STRING_LENGTH (MD5_DIGEST_LENGTH*2+1)
82
83 char* md5str( char str[MD5_DIGEST_STRING_LENGTH], unsigned char* data, int len );
84
85 #endif
86
87

Back to OSDN">Back to OSDN
ViewVC Help
Powered by ViewVC 1.1.26