]> git.saurik.com Git - apple/libc.git/blobdiff - include/db.h
Libc-339.tar.gz
[apple/libc.git] / include / db.h
index 1e4cce86c81f2baf24055a39686eac999f2f7379..bd1eb9f169347f3634b722ce32f9ef102793fd59 100644 (file)
@@ -1,26 +1,29 @@
 /*
- * Copyright (c) 2000 Apple Computer, Inc. All rights reserved.
+ * Copyright (c) 2003 Apple Computer, Inc. All rights reserved.
  *
  * @APPLE_LICENSE_HEADER_START@
  * 
- * The contents of this file constitute Original Code as defined in and
- * are subject to the Apple Public Source License Version 1.1 (the
- * "License").  You may not use this file except in compliance with the
- * License.  Please obtain a copy of the License at
- * http://www.apple.com/publicsource and read it before using this file.
+ * Copyright (c) 1999-2003 Apple Computer, Inc.  All Rights Reserved.
  * 
- * This Original Code and all software distributed under the License are
- * distributed on an "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, EITHER
+ * This file contains Original Code and/or Modifications of Original Code
+ * as defined in and that are subject to the Apple Public Source License
+ * Version 2.0 (the 'License'). You may not use this file except in
+ * compliance with the License. Please obtain a copy of the License at
+ * http://www.opensource.apple.com/apsl/ and read it before using this
+ * file.
+ * 
+ * The Original Code and all software distributed under the License are
+ * distributed on an 'AS IS' basis, WITHOUT WARRANTY OF ANY KIND, EITHER
  * EXPRESS OR IMPLIED, AND APPLE HEREBY DISCLAIMS ALL SUCH WARRANTIES,
  * INCLUDING WITHOUT LIMITATION, ANY WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE OR NON-INFRINGEMENT.  Please see the
- * License for the specific language governing rights and limitations
- * under the License.
+ * FITNESS FOR A PARTICULAR PURPOSE, QUIET ENJOYMENT OR NON-INFRINGEMENT.
+ * Please see the License for the specific language governing rights and
+ * limitations under the License.
  * 
  * @APPLE_LICENSE_HEADER_END@
  */
 /*-
- * Copyright (c) 1990, 1993
+ * Copyright (c) 1990, 1993, 1994
  *     The Regents of the University of California.  All rights reserved.
  *
  * Redistribution and use in source and binary forms, with or without
@@ -51,7 +54,8 @@
  * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  * SUCH DAMAGE.
  *
- *     @(#)db.h        8.4 (Berkeley) 2/21/94
+ *     @(#)db.h        8.7 (Berkeley) 6/16/94
+ * $FreeBSD: src/include/db.h,v 1.5 2002/03/26 01:35:05 bde Exp $
  */
 
 #ifndef _DB_H_
@@ -120,14 +124,14 @@ typedef enum { DB_BTREE, DB_HASH, DB_RECNO } DBTYPE;
 /* Access method description structure. */
 typedef struct __db {
        DBTYPE type;                    /* Underlying db type. */
-       int (*close)    __P((struct __db *));
-       int (*del)      __P((const struct __db *, const DBT *, u_int));
-       int (*get)      __P((const struct __db *, const DBT *, DBT *, u_int));
-       int (*put)      __P((const struct __db *, DBT *, const DBT *, u_int));
-       int (*seq)      __P((const struct __db *, DBT *, DBT *, u_int));
-       int (*sync)     __P((const struct __db *, u_int));
+       int (*close)(struct __db *);
+       int (*del)(const struct __db *, const DBT *, u_int);
+       int (*get)(const struct __db *, const DBT *, DBT *, u_int);
+       int (*put)(const struct __db *, DBT *, const DBT *, u_int);
+       int (*seq)(const struct __db *, DBT *, DBT *, u_int);
+       int (*sync)(const struct __db *, u_int);
        void *internal;                 /* Access method private. */
-       int (*fd)       __P((const struct __db *));
+       int (*fd)(const struct __db *);
 } DB;
 
 #define        BTREEMAGIC      0x053162
@@ -142,9 +146,9 @@ typedef struct {
        int     minkeypage;     /* minimum keys per page */
        u_int   psize;          /* page size */
        int     (*compare)      /* comparison function */
-           __P((const DBT *, const DBT *));
+           (const DBT *, const DBT *);
        size_t  (*prefix)       /* prefix function */
-           __P((const DBT *, const DBT *));
+           (const DBT *, const DBT *);
        int     lorder;         /* byte order */
 } BTREEINFO;
 
@@ -158,7 +162,7 @@ typedef struct {
        u_int   nelem;          /* number of elements */
        u_int   cachesize;      /* bytes to cache */
        u_int32_t               /* hash function */
-               (*hash) __P((const void *, size_t));
+               (*hash)(const void *, size_t);
        int     lorder;         /* byte order */
 } HASHINFO;
 
@@ -227,13 +231,13 @@ typedef struct {
 #endif
 
 __BEGIN_DECLS
-DB *dbopen __P((const char *, int, int, DBTYPE, const void *));
+DB *dbopen(const char *, int, int, DBTYPE, const void *);
 
 #ifdef __DBINTERFACE_PRIVATE
-DB     *__bt_open __P((const char *, int, int, const BTREEINFO *, int));
-DB     *__hash_open __P((const char *, int, int, const HASHINFO *, int));
-DB     *__rec_open __P((const char *, int, int, const RECNOINFO *, int));
-void    __dbpanic __P((DB *dbp));
+DB     *__bt_open(const char *, int, int, const BTREEINFO *, int);
+DB     *__hash_open(const char *, int, int, const HASHINFO *, int);
+DB     *__rec_open(const char *, int, int, const RECNOINFO *, int);
+void    __dbpanic(DB *dbp);
 #endif
 __END_DECLS
 #endif /* !_DB_H_ */