2001-05-23 15:26:42 +02:00
|
|
|
/*
|
|
|
|
* PROGRAM: JRD Access Method
|
|
|
|
* MODULE: tra_proto.h
|
2003-10-29 11:53:47 +01:00
|
|
|
* DESCRIPTION: Prototype header file for tra.cpp
|
2001-05-23 15:26:42 +02:00
|
|
|
*
|
|
|
|
* The contents of this file are subject to the Interbase Public
|
|
|
|
* License Version 1.0 (the "License"); you may not use this file
|
|
|
|
* except in compliance with the License. You may obtain a copy
|
|
|
|
* of the License at http://www.Inprise.com/IPL.html
|
|
|
|
*
|
|
|
|
* Software distributed under the License is distributed on an
|
|
|
|
* "AS IS" basis, WITHOUT WARRANTY OF ANY KIND, either express
|
|
|
|
* or implied. See the License for the specific language governing
|
|
|
|
* rights and limitations under the License.
|
|
|
|
*
|
|
|
|
* The Original Code was created by Inprise Corporation
|
|
|
|
* and its predecessors. Portions created by Inprise Corporation are
|
|
|
|
* Copyright (C) Inprise Corporation.
|
|
|
|
*
|
|
|
|
* All Rights Reserved.
|
|
|
|
* Contributor(s): ______________________________________.
|
|
|
|
*/
|
|
|
|
|
2003-10-03 03:53:34 +02:00
|
|
|
#ifndef JRD_TRA_PROTO_H
|
|
|
|
#define JRD_TRA_PROTO_H
|
2001-05-23 15:26:42 +02:00
|
|
|
|
|
|
|
#include "../jrd/req.h"
|
|
|
|
|
2004-03-18 06:56:06 +01:00
|
|
|
class Attachment;
|
2004-02-20 07:43:27 +01:00
|
|
|
class jrd_tra;
|
|
|
|
class Resource;
|
2004-03-07 08:58:55 +01:00
|
|
|
class Database;
|
2004-03-18 06:56:06 +01:00
|
|
|
struct blk;
|
2004-02-20 07:43:27 +01:00
|
|
|
|
2004-03-11 06:04:26 +01:00
|
|
|
bool TRA_active_transactions(thread_db*, Database*);
|
|
|
|
void TRA_cleanup(thread_db*);
|
|
|
|
void TRA_commit(thread_db*, jrd_tra*, const bool);
|
|
|
|
void TRA_extend_tip(thread_db*, ULONG, struct win *);
|
|
|
|
int TRA_fetch_state(thread_db*, SLONG);
|
2004-03-18 06:56:06 +01:00
|
|
|
void TRA_get_inventory(thread_db*, UCHAR*, ULONG, ULONG);
|
2004-03-11 06:04:26 +01:00
|
|
|
int TRA_get_state(thread_db*, SLONG);
|
2003-11-06 04:03:36 +01:00
|
|
|
|
2001-05-23 15:26:42 +02:00
|
|
|
#ifdef SUPERSERVER_V2
|
2004-03-11 06:04:26 +01:00
|
|
|
void TRA_header_write(thread_db*, Database*, SLONG);
|
2001-05-23 15:26:42 +02:00
|
|
|
#endif
|
2004-03-11 06:04:26 +01:00
|
|
|
void TRA_init(thread_db*);
|
2004-03-07 08:58:55 +01:00
|
|
|
void TRA_invalidate(Database*, ULONG);
|
2004-03-18 06:56:06 +01:00
|
|
|
void TRA_link_transaction(thread_db*, jrd_tra*);
|
|
|
|
void TRA_post_resources(thread_db*, jrd_tra*, Resource*);
|
2004-03-11 06:04:26 +01:00
|
|
|
bool TRA_precommited(thread_db*, SLONG, SLONG);
|
|
|
|
void TRA_prepare(thread_db*, jrd_tra*, USHORT, const UCHAR*);
|
|
|
|
jrd_tra* TRA_reconnect(thread_db*, const UCHAR*, USHORT);
|
2004-03-18 06:56:06 +01:00
|
|
|
void TRA_release_transaction(thread_db*, jrd_tra*);
|
2004-03-11 06:04:26 +01:00
|
|
|
void TRA_rollback(thread_db*, jrd_tra*, const bool);
|
2004-03-18 06:56:06 +01:00
|
|
|
void TRA_set_state(thread_db*, jrd_tra*, SLONG, SSHORT);
|
|
|
|
void TRA_shutdown_attachment(thread_db*, Attachment*);
|
|
|
|
int TRA_snapshot_state(thread_db*, const jrd_tra*, SLONG);
|
2004-03-11 06:04:26 +01:00
|
|
|
jrd_tra* TRA_start(thread_db*, int, const SCHAR*);
|
2004-03-18 06:56:06 +01:00
|
|
|
int TRA_state(const UCHAR*, ULONG, ULONG);
|
|
|
|
bool TRA_sweep(thread_db*, jrd_tra*);
|
|
|
|
Lock* TRA_transaction_lock(thread_db*, blk*);
|
|
|
|
int TRA_wait(thread_db*, jrd_tra*, SLONG, bool);
|
2001-05-23 15:26:42 +02:00
|
|
|
|
2003-10-03 03:53:34 +02:00
|
|
|
#endif // JRD_TRA_PROTO_H
|
2003-10-29 11:53:47 +01:00
|
|
|
|