/*
 * budb_client.h:
 * This file is automatically generated; please do not edit it.
 */
/* Including ./budb_client.p.h at beginning of budb_client.h file. */

/*
 * Copyright 2000, International Business Machines Corporation and others.
 * All Rights Reserved.
 *
 * This software has been released under the terms of the IBM Public
 * License.  For details, see the LICENSE file in the top-level source
 * directory or online at http://www.openafs.org/dl/license10.html
 */

#ifndef __BUDB_CLIENT__
#define __BUDB_CLIENT__

#include <ubik.h>
#ifndef BUDB_MAJORVERSION	/* get the installed RPC stuff */
#include <sys/types.h>
#include <rx/xdr.h>
#include <afs/budb.h>
#endif


/* for ubik_Call_SingleServer */

#define UF_SINGLESERVER         1	/* begin single server operation */
#define UF_END_SINGLESERVER     2	/* terminate single server operation */


/* handle for the ubik database connection */

struct udbHandleS {
    afs_int32 uh_scIndex;	/* what type of sec. object */
    struct rx_securityClass *uh_secobj;	/* security object */
    struct rx_connection *uh_serverConn[MAXSERVERS];	/* server connections */
    struct ubik_client *uh_client;	/* ubik client handle */
    afs_uint32 uh_instanceId;	/* instance of client */
};

typedef struct udbHandleS udbHandleT;
typedef udbHandleT *udbHandleP;

/* suggested text block management structure */

struct udbClientTextS {
    char *textName;		/* for info. only */
    afs_int32 textType;		/* used as key for access */
    afs_uint32 textVersion;	/* version # for cache mgmt */
    afs_uint32 lockHandle;	/* for atomicity */
    afs_int32 textSize;		/* no. of bytes */
    FILE *textStream;		/* file stream or NULL */
};

typedef struct udbClientTextS udbClientTextT;
typedef udbClientTextT *udbClientTextP;

#endif

/* End of prolog file ./budb_client.p.h. */

#define BUDB_DUMPIDEXISTS                        (156303872L)
#define BUDB_NODUMPID                            (156303873L)
#define BUDB_NODUMPNAME                          (156303874L)
#define BUDB_NOTAPENAME                          (156303875L)
#define BUDB_NOVOLUMENAME                        (156303876L)
#define BUDB_NOENT                               (156303877L)
#define BUDB_TAPENOTINUSE                        (156303878L)
#define BUDB_DUMPFAILED                          (156303879L)
#define BUDB_NOTPERMITTED                        (156303880L)
#define BUDB_VERSIONMISMATCH                     (156303881L)
#define BUDB_BADARGUMENT                         (156303882L)
#define BUDB_BADPROTOCOL                         (156303883L)
#define BUDB_BADFLAGS                            (156303884L)
#define BUDB_LIST2BIG                            (156303885L)
#define BUDB_ENDOFLIST                           (156303886L)
#define BUDB_BLOCKTYPE                           (156303887L)
#define BUDB_NOTLOCKED                           (156303888L)
#define BUDB_LOCKED                              (156303889L)
#define BUDB_SELFLOCKED                          (156303890L)
#define BUDB_OLDINTERFACE                        (156303891L)
#define BUDB_IO                                  (156303892L)
#define BUDB_ADDR                                (156303893L)
#define BUDB_DATABASEINCONSISTENT                (156303894L)
#define BUDB_INTERNALERROR                       (156303895L)
#define BUDB_NOCELLS                             (156303896L)
#define BUDB_NOCELL                              (156303897L)
#define BUDB_EMPTY                               (156303898L)
#define BUDB_UBIKINIT                            (156303899L)
#define BUDB_ALLOCFAIL                           (156303900L)
#define BUDB_NOMEM                               (156303901L)
#define BUDB_NOTINITIALDUMP                      (156303902L)
#define BUDB_DUMPNOTINUSE                        (156303903L)
extern void initialize_BUDB_error_table(void);
#define ERROR_TABLE_BASE_BUDB (156303872L)

/* for compatibility with older versions... */
#define init_BUDB_err_tbl initialize_BUDB_error_table
#define BUDB_err_base ERROR_TABLE_BASE_BUDB

/* for compatibility with other users... */
#define ERROR_TABLE_BASE_budb (156303872L)
#define init_budb_err_tbl initialize_BUDB_error_table
#define initialize_budb_error_table initialize_BUDB_error_table
#define budb_err_base ERROR_TABLE_BASE_budb
