// Borland C++ Builder
// Copyright (c) 1995, 2005 by Borland Software Corporation
// All rights reserved

// (DO NOT EDIT: machine generated header) 'Fib.pas' rev: 10.00

#ifndef FibHPP
#define FibHPP

#pragma delphiheader begin
#pragma option push
#pragma option -w-      // All warnings off
#pragma option -Vx      // Zero-length empty class member functions
#pragma pack(push,8)
#include <System.hpp>	// Pascal unit
#include <Sysinit.hpp>	// Pascal unit
#include <Windows.hpp>	// Pascal unit
#include <Sysutils.hpp>	// Pascal unit
#include <Classes.hpp>	// Pascal unit
#include <Ibase.hpp>	// Pascal unit
#include <Ib_intf.hpp>	// Pascal unit
#include <Ib_externals.hpp>	// Pascal unit
#include <Db.hpp>	// Pascal unit

//-- user supplied -----------------------------------------------------------

namespace Fib
{
//-- type declarations -------------------------------------------------------
class DELPHICLASS EFIBError;
class PASCALIMPLEMENTATION EFIBError : public Db::EDatabaseError 
{
	typedef Db::EDatabaseError inherited;
	
private:
	int FSQLCode;
	int FIBErrorCode;
	AnsiString FRaiserName;
	AnsiString FSQLMessage;
	AnsiString FIBMessage;
	AnsiString FCustomMessage;
	AnsiString FMsg;
	System::TObject* SenderObj;
	void __fastcall RebuildMessage(void);
	void __fastcall SetSQLMessage(AnsiString Value);
	void __fastcall SetIBMessage(AnsiString Value);
	void __fastcall SetCustomMessage(const AnsiString Value);
	void __fastcall SetMsg(const AnsiString Value);
	
public:
	__fastcall EFIBError(int ASQLCode, const AnsiString aMsg, System::TObject* Sender);
	__fastcall EFIBError(int ASQLCode, const AnsiString IBMsg, const AnsiString SQLMsg, const AnsiString CstmMsg, System::TObject* Sender);
	__property int SQLCode = {read=FSQLCode, nodefault};
	__property int IBErrorCode = {read=FIBErrorCode, nodefault};
	__property AnsiString RaiserName = {read=FRaiserName, write=FRaiserName};
	__property AnsiString SQLMessage = {read=FSQLMessage, write=SetSQLMessage};
	__property AnsiString IBMessage = {read=FIBMessage, write=SetIBMessage};
	__property AnsiString CustomMessage = {read=FCustomMessage, write=SetCustomMessage};
	__property AnsiString Msg = {read=FMsg, write=SetMsg};
public:
	#pragma option push -w-inl
	/* Exception.CreateFmt */ inline __fastcall EFIBError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size) : Db::EDatabaseError(Msg, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateRes */ inline __fastcall EFIBError(int Ident)/* overload */ : Db::EDatabaseError(Ident) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmt */ inline __fastcall EFIBError(int Ident, System::TVarRec const * Args, const int Args_Size)/* overload */ : Db::EDatabaseError(Ident, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateHelp */ inline __fastcall EFIBError(const AnsiString Msg, int AHelpContext) : Db::EDatabaseError(Msg, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateFmtHelp */ inline __fastcall EFIBError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size, int AHelpContext) : Db::EDatabaseError(Msg, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResHelp */ inline __fastcall EFIBError(int Ident, int AHelpContext)/* overload */ : Db::EDatabaseError(Ident, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmtHelp */ inline __fastcall EFIBError(System::PResStringRec ResStringRec, System::TVarRec const * Args, const int Args_Size, int AHelpContext)/* overload */ : Db::EDatabaseError(ResStringRec, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TObject.Destroy */ inline __fastcall virtual ~EFIBError(void) { }
	#pragma option pop
	
};


class DELPHICLASS EFIBInterBaseError;
class PASCALIMPLEMENTATION EFIBInterBaseError : public EFIBError 
{
	typedef EFIBError inherited;
	
public:
	#pragma option push -w-inl
	/* EFIBError.Create */ inline __fastcall EFIBInterBaseError(int ASQLCode, const AnsiString aMsg, System::TObject* Sender) : EFIBError(ASQLCode, aMsg, Sender) { }
	#pragma option pop
	#pragma option push -w-inl
	/* EFIBError.CreateEx */ inline __fastcall EFIBInterBaseError(int ASQLCode, const AnsiString IBMsg, const AnsiString SQLMsg, const AnsiString CstmMsg, System::TObject* Sender) : EFIBError(ASQLCode, IBMsg, SQLMsg, CstmMsg, Sender) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* Exception.CreateFmt */ inline __fastcall EFIBInterBaseError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size) : EFIBError(Msg, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateRes */ inline __fastcall EFIBInterBaseError(int Ident)/* overload */ : EFIBError(Ident) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmt */ inline __fastcall EFIBInterBaseError(int Ident, System::TVarRec const * Args, const int Args_Size)/* overload */ : EFIBError(Ident, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateHelp */ inline __fastcall EFIBInterBaseError(const AnsiString Msg, int AHelpContext) : EFIBError(Msg, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateFmtHelp */ inline __fastcall EFIBInterBaseError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size, int AHelpContext) : EFIBError(Msg, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResHelp */ inline __fastcall EFIBInterBaseError(int Ident, int AHelpContext)/* overload */ : EFIBError(Ident, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmtHelp */ inline __fastcall EFIBInterBaseError(System::PResStringRec ResStringRec, System::TVarRec const * Args, const int Args_Size, int AHelpContext)/* overload */ : EFIBError(ResStringRec, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TObject.Destroy */ inline __fastcall virtual ~EFIBInterBaseError(void) { }
	#pragma option pop
	
};


class DELPHICLASS EFIBClientError;
class PASCALIMPLEMENTATION EFIBClientError : public EFIBError 
{
	typedef EFIBError inherited;
	
public:
	#pragma option push -w-inl
	/* EFIBError.Create */ inline __fastcall EFIBClientError(int ASQLCode, const AnsiString aMsg, System::TObject* Sender) : EFIBError(ASQLCode, aMsg, Sender) { }
	#pragma option pop
	#pragma option push -w-inl
	/* EFIBError.CreateEx */ inline __fastcall EFIBClientError(int ASQLCode, const AnsiString IBMsg, const AnsiString SQLMsg, const AnsiString CstmMsg, System::TObject* Sender) : EFIBError(ASQLCode, IBMsg, SQLMsg, CstmMsg, Sender) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* Exception.CreateFmt */ inline __fastcall EFIBClientError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size) : EFIBError(Msg, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateRes */ inline __fastcall EFIBClientError(int Ident)/* overload */ : EFIBError(Ident) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmt */ inline __fastcall EFIBClientError(int Ident, System::TVarRec const * Args, const int Args_Size)/* overload */ : EFIBError(Ident, Args, Args_Size) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateHelp */ inline __fastcall EFIBClientError(const AnsiString Msg, int AHelpContext) : EFIBError(Msg, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateFmtHelp */ inline __fastcall EFIBClientError(const AnsiString Msg, System::TVarRec const * Args, const int Args_Size, int AHelpContext) : EFIBError(Msg, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResHelp */ inline __fastcall EFIBClientError(int Ident, int AHelpContext)/* overload */ : EFIBError(Ident, AHelpContext) { }
	#pragma option pop
	#pragma option push -w-inl
	/* Exception.CreateResFmtHelp */ inline __fastcall EFIBClientError(System::PResStringRec ResStringRec, System::TVarRec const * Args, const int Args_Size, int AHelpContext)/* overload */ : EFIBError(ResStringRec, Args, Args_Size, AHelpContext) { }
	#pragma option pop
	
public:
	#pragma option push -w-inl
	/* TObject.Destroy */ inline __fastcall virtual ~EFIBClientError(void) { }
	#pragma option pop
	
};


#pragma option push -b-
enum TIBErrorMessage { ShowSQLCode, ShowIBMessage, ShowSQLMessage, ShowRaiserName };
#pragma option pop

typedef Set<TIBErrorMessage, ShowSQLCode, ShowRaiserName>  TIBErrorMessages;

#pragma option push -b-
enum TFIBClientError { feUnknownError, feNotSupported, feNotPermitted, feFileAccessError, feConnectionTimeout, feCannotSetDatabase, feCannotSetTransaction, feOperationCancelled, feDPBConstantNotSupported, feDPBConstantUnknown, feTPBConstantNotSupported, feTPBConstantUnknown, feDatabaseClosed, feDatabaseOpen, feDatabaseNameMissing, feNotInTransaction, feInTransaction, feTimeoutNegative, feNoDatabasesInTransaction, feUpdateWrongDB, feUpdateWrongTR, feDatabaseNotAssigned, feTransactionNotAssigned, feXSQLDAIndexOutOfRange, feXSQLDANameDoesNotExist, feEOF, feBOF, feInvalidStatementHandle, feDatasetOpen, feDatasetClosed, feUnknownSQLDataType, feInvalidColumnIndex, feInvalidParamColumnIndex, feInvalidDataConversion, feColumnIsNotNullable, feBlobCannotBeRead, feBlobCannotBeWritten, feEmptyQuery, feCannotOpenNonSQLSelect, feNoFieldAccess, feFieldReadOnly, feFieldNotFound, feNotInEditState, feNotEditing, feCannotInsert, feCannotPost, feCannotUpdate, feCannotDelete, feCannotRefresh, feBufferNotSet, feCircularReference
	, feSQLParseError, feUserAbort, feDataSetUniDirectional, feCannotCreateSharedResource, feWindowsAPIError, feColumnListsDontMatch, feColumnTypesDontMatch, feCantEndSharedTransaction, feNotIsArrayField, feWrongDimension, feSQLDialectInvalid, feIBMissing, feIB60feature, feInterBaseInstallMissing, feServiceActive, feServiceInActive, feServerNameMissing, feQueryParamsError, feStartParamsError, feOutputParsingError, feUseSpecificProcedures, feSPBConstantNotSupported, feSPBConstantUnknown, feFieldSizeMismatch, feCantUseLimitedCache, feFieldListEmpty, feCantUseField, feFB2feature };
#pragma option pop

typedef int TStatusVector[20];

typedef TStatusVector *PStatusVector;

typedef AnsiString fib__4[79];

typedef AnsiString fib__5[83];

typedef AnsiString fib__6[21];

typedef bool __fastcall (*TpFIBLoginDialog)(const AnsiString ADatabaseName, AnsiString &AUserName, AnsiString &APassword, AnsiString &ARoleName);

//-- var, const, procedure ---------------------------------------------------
extern PACKAGE int FIBPlusVersion;
extern PACKAGE int FIBPlusBuild;
#define FIBPlusBuildDate "12.05.2007"
extern PACKAGE int FIBCustomBuild;
#define FIBVersionNote "Release"
#define FIBPalette "FIBPlus"
#define CRLF "\r\n"
static const Word FIBLocalBufferLength = 0x200;
static const Word FIBBigLocalBufferLength = 0x400;
static const Word FIBHugeLocalBufferLength = 0x5000;
extern PACKAGE AnsiString FIBErrorMessages[79];
#define DPBPrefix "isc_dpb_"
extern PACKAGE AnsiString DPBConstantNames[83];
#define TPBPrefix "isc_tpb_"
extern PACKAGE AnsiString TPBConstantNames[21];
static const char SQLDecimalSeparator = '\x2e';
extern PACKAGE System::ResourceString _TrueStr;
#define Fib_TrueStr System::LoadResourceString(&Fib::_TrueStr)
extern PACKAGE System::ResourceString _FalseStr;
#define Fib_FalseStr System::LoadResourceString(&Fib::_FalseStr)
extern PACKAGE _RTL_CRITICAL_SECTION FIBCS;
extern PACKAGE unsigned hFIBTLGlobals;
extern PACKAGE TpFIBLoginDialog pFIBLoginDialog;
extern PACKAGE TIBErrorMessages IBErrorMessages;
extern PACKAGE void __fastcall FIBAlloc(void *p, unsigned OldSize, unsigned NewSize);
extern PACKAGE void __fastcall RegisterErrorHandler(Classes::TComponent* aErrorHandler);
extern PACKAGE void __fastcall UnRegisterErrorHandler(void);
extern PACKAGE bool __fastcall ErrorHandlerRegistered(void);
extern PACKAGE void __fastcall FIBError(TFIBClientError ErrMess, System::TVarRec const * Args, const int Args_Size);
extern PACKAGE void __fastcall FIBErrorEx(const AnsiString ErrMess, System::TVarRec const * Args, const int Args_Size);
extern PACKAGE void __fastcall IBError(Ib_intf::_di_IIBClientLibrary ClientLibrary, System::TObject* Sender);
extern PACKAGE Ib_externals::PISC_STATUS __fastcall StatusVector(void);
extern PACKAGE PStatusVector __fastcall StatusVectorArray(void);
extern PACKAGE bool __fastcall CheckStatusVector(int * ErrorCodes, const int ErrorCodes_Size);
extern PACKAGE AnsiString __fastcall StatusVectorAsText();
extern PACKAGE void __fastcall GenerateDPB(Classes::TStrings* sl, AnsiString &DPB, short &DPBLength);
extern PACKAGE void __fastcall GenerateTPB(Classes::TStrings* sl, AnsiString &TPB, short &TPBLength);
extern PACKAGE void __fastcall SetIBErrorMessages(TIBErrorMessages Value);
extern PACKAGE TIBErrorMessages __fastcall GetIBErrorMessages(void);

}	/* namespace Fib */
using namespace Fib;
#pragma pack(pop)
#pragma option pop

#pragma delphiheader end.
//-- end unit ----------------------------------------------------------------
#endif	// Fib
