ViewVC Help
View File | Revision Log | Show Annotations | Download File | View Changeset | Root Listing
root/public/ibx/branches/udr/client/IB.pas
(Generate patch)

Comparing ibx/branches/journaling/fbintf/IB.pas (file contents):
Revision 362 by tony, Tue Dec 7 13:27:39 2021 UTC vs.
Revision 363 by tony, Tue Dec 7 13:30:05 2021 UTC

# Line 135 | Line 135 | const
135    {Interface version information}
136    FBIntf_Major = 1;
137    FBIntf_Minor = 3;
138 <  FBIntf_Release = 3;
139 <  FBIntf_Version = '1.3.3';
138 >  FBIntf_Release = 2;
139 >  FBIntf_Version = '1.3.2';
140  
141   const
142    {DPB, TPB and SPB Parameter Block Name Prefixes}
# Line 859 | Line 859 | type
859  
860    ITPBItem = interface(IParameterBlockItemWithTypeName)
861      ['{544c1f2b-7c12-4a87-a4a5-face7ea72671}']
862    function getParamTypeName: AnsiString;
862    end;
863  
864    ITPB = interface(IParameterBlockWithTypeNames<ITPBItem>)
865      ['{7369b0ff-defe-437b-81fe-19b211d42d25}']
866 +    function AsText: AnsiString;
867    end;
868  
869    {The ITransactionAction interface provides access to a Transaction once it
# Line 884 | Line 884 | type
884      function GetInTransaction: boolean;
885      function GetIsReadOnly: boolean;
886      function GetTransactionID: integer;
887 +    function GetJournalingActive(attachment: IAttachment): boolean;
888 +    function GetDefaultCompletion: TTransactionCompletion;
889      procedure PrepareForCommit; {Two phase commit - stage 1}
890      procedure Commit(Force: boolean=false);
891      procedure CommitRetaining;
# Line 894 | Line 896 | type
896      function GetAttachment(index: integer): IAttachment;
897      function GetTrInformation(Requests: array of byte): ITrInformation; overload;
898      function GetTrInformation(Request: byte): ITrInformation; overload;
899 +    function GetTransactionName: AnsiString;
900 +    procedure SetTransactionName(aValue: AnsiString);
901      property InTransaction: boolean read GetInTransaction;
902 +    property TransactionName: AnsiString read GetTransactionName write SetTransactionName;
903    end;
904  
905    { The IEvents Interface is used to handle events from a single database. The
# Line 1057 | Line 1062 | type
1062       ['{e676067b-1cf4-4eba-9256-9724f57e0d16}']
1063     end;
1064  
1065 +   {Journaling options. Default is [joReadWriteTransactions,joModifyQueries] }
1066 +
1067 +   TJournalOption = (joReadOnlyTransactions, joReadWriteTransactions,
1068 +                     joModifyQueries, joReadOnlyQueries);
1069 +
1070 +   TJournalOptions = set of TJournalOption;
1071 +
1072    {The IAttachment interface provides access to a Database Connection. It may be
1073     used to:
1074  
# Line 1094 | Line 1106 | type
1106      procedure Disconnect(Force: boolean=false);
1107      function IsConnected: boolean;
1108      procedure DropDatabase;
1109 <    function StartTransaction(TPB: array of byte; DefaultCompletion: TTransactionCompletion=taCommit): ITransaction; overload;
1110 <    function StartTransaction(TPB: ITPB; DefaultCompletion: TTransactionCompletion=taCommit): ITransaction; overload;
1109 >    function StartTransaction(TPB: array of byte;
1110 >                              DefaultCompletion: TTransactionCompletion=taCommit;
1111 >                              aName: AnsiString=''): ITransaction; overload;
1112 >    function StartTransaction(TPB: ITPB;
1113 >                              DefaultCompletion: TTransactionCompletion=taCommit;
1114 >                              aName: AnsiString=''): ITransaction; overload;
1115      procedure ExecImmediate(transaction: ITransaction; sql: AnsiString; SQLDialect: integer); overload;
1116      procedure ExecImmediate(TPB: array of byte; sql: AnsiString; SQLDialect: integer); overload;
1117      procedure ExecImmediate(transaction: ITransaction; sql: AnsiString); overload;
# Line 1166 | Line 1182 | type
1182  
1183      {Database Information}
1184      function GetSQLDialect: integer;
1185 +    function GetAttachmentID: integer;
1186      function GetBlobMetaData(Transaction: ITransaction; tableName, columnName: AnsiString): IBlobMetaData;
1187      function GetArrayMetaData(Transaction: ITransaction; tableName, columnName: AnsiString): IArrayMetaData;
1188      function GetDBInformation(Requests: array of byte): IDBInformation; overload;
# Line 1182 | Line 1199 | type
1199      function HasDecFloatSupport: boolean;
1200      function HasBatchMode: boolean;
1201      function HasScollableCursors: boolean;
1202 +    function HasTable(aTableName: AnsiString): boolean;
1203  
1204      {Character Sets}
1205      function HasDefaultCharSet: boolean;
# Line 1197 | Line 1215 | type
1215      {Time Zone Database}
1216      function GetTimeZoneServices: ITimeZoneServices;
1217      function HasTimeZoneSupport: boolean;
1218 +
1219 +    {Client side Journaling}
1220 +    function JournalingActive: boolean;
1221 +    function GetJournalOptions: TJournalOptions;
1222 +    function StartJournaling(aJournalLogFile: AnsiString): integer; overload;
1223 +    function StartJournaling(aJournalLogFile: AnsiString; Options: TJournalOptions): integer; overload;
1224 +    procedure StopJournaling(RetainJournal: boolean);
1225   end;
1226  
1227    TProtocolAll = (TCP, SPX, NamedPipe, Local, inet, inet4, inet6, wnet, xnet, unknownProtocol);
# Line 1365 | Line 1390 | type
1390      {Start Transaction against multiple databases}
1391      function AllocateTPB: ITPB;
1392      function StartTransaction(Attachments: array of IAttachment;
1393 <             TPB: array of byte; DefaultCompletion: TTransactionCompletion=taCommit): ITransaction; overload;
1393 >             TPB: array of byte; DefaultCompletion: TTransactionCompletion=taCommit;
1394 >             aName: AnsiString=''): ITransaction; overload;
1395      function StartTransaction(Attachments: array of IAttachment;
1396 <             TPB: ITPB; DefaultCompletion: TTransactionCompletion=taCommit): ITransaction; overload;
1396 >             TPB: ITPB; DefaultCompletion: TTransactionCompletion=taCommit;
1397 >             aName: AnsiString=''): ITransaction; overload;
1398  
1399      {Service Manager}
1400      function HasServiceAPI: boolean;
# Line 1448 | Line 1475 | procedure CheckIBLoaded;
1475  
1476   function LoadFBLibrary(aLibPathName: string): IFirebirdLibrary;
1477  
1478 + {$if not declared(NULL)} {Needed for Delphi}
1479 + function Null: Variant;       // Null standard constant
1480 + {$define NEEDNULLFUNCTION}
1481 + {$ifend}
1482  
1483   implementation
1484  
1485 < uses FBClientAPI
1485 > uses FBClientAPI {$if not declared(NULL)}, Variants {$ifend}
1486    {$IFDEF USELEGACYFIREBIRDAPI}, FB25ClientAPI {$ENDIF}
1487    {$IFDEF USEFIREBIRD3API}, FB30ClientAPI {$ENDIF};
1488  
# Line 1556 | Line 1587 | begin
1587    FIBErrorCode := AIBErrorCode;
1588   end;
1589  
1590 + {$ifdef NEEDNULLFUNCTION}
1591 + function Null: Variant;       // Null standard constant
1592 +   begin
1593 +     VarClearProc(TVarData(Result));
1594 +     TVarData(Result).VType := varnull;
1595 +   end;
1596 + {$endif}
1597  
1598   initialization
1599    FDefaultFBLibrary := nil;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines