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

Comparing ibx/branches/journaling/fbintf/client/3.0/FB30Attachment.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 53 | Line 53 | type
53      procedure SetUseRemoteICU(aValue: boolean);
54    protected
55      procedure CheckHandle; override;
56 +    function GetAttachment: IAttachment; override;
57    public
58      constructor Create(api: TFB30ClientAPI; DatabaseName: AnsiString; aDPB: IDPB;
59            RaiseExceptionOnConnectError: boolean);
# Line 71 | Line 72 | type
72      procedure Disconnect(Force: boolean=false); override;
73      function IsConnected: boolean; override;
74      procedure DropDatabase;
75 <    function StartTransaction(TPB: array of byte; DefaultCompletion: TTransactionCompletion): ITransaction; override;
76 <    function StartTransaction(TPB: ITPB; DefaultCompletion: TTransactionCompletion): ITransaction; override;
75 >    function StartTransaction(TPB: array of byte; DefaultCompletion: TTransactionCompletion; aName: AnsiString=''): ITransaction; override;
76 >    function StartTransaction(TPB: ITPB; DefaultCompletion: TTransactionCompletion; aName: AnsiString=''): ITransaction; override;
77      procedure ExecImmediate(transaction: ITransaction; sql: AnsiString; aSQLDialect: integer); override;
78      function Prepare(transaction: ITransaction; sql: AnsiString; aSQLDialect: integer; CursorName: AnsiString=''): IStatement; override;
79      function PrepareWithNamedParameters(transaction: ITransaction; sql: AnsiString;
# Line 172 | Line 173 | begin
173      IBError(ibxeDatabaseClosed,[nil]);
174   end;
175  
176 + function TFB30Attachment.GetAttachment: IAttachment;
177 + begin
178 +  Result := self;
179 + end;
180 +
181   constructor TFB30Attachment.Create(api: TFB30ClientAPI; DatabaseName: AnsiString; aDPB: IDPB;
182    RaiseExceptionOnConnectError: boolean);
183   begin
# Line 277 | Line 283 | end;
283  
284   procedure TFB30Attachment.Disconnect(Force: boolean);
285   begin
286 +  inherited Disconnect(Force);
287    if IsConnected then
288      with FFirebird30ClientAPI do
289      begin
# Line 303 | Line 310 | begin
310      with FFirebird30ClientAPI do
311      begin
312        EndAllTransactions;
313 +      EndSession(false);
314        FAttachmentIntf.dropDatabase(StatusIntf);
315        Check4DataBaseError;
316        FAttachmentIntf := nil;
# Line 310 | Line 318 | begin
318   end;
319  
320   function TFB30Attachment.StartTransaction(TPB: array of byte;
321 <  DefaultCompletion: TTransactionCompletion): ITransaction;
321 >  DefaultCompletion: TTransactionCompletion; aName: AnsiString): ITransaction;
322   begin
323    CheckHandle;
324 <  Result := TFB30Transaction.Create(FFirebird30ClientAPI,self,TPB,DefaultCompletion);
324 >  Result := TFB30Transaction.Create(FFirebird30ClientAPI,self,TPB,DefaultCompletion, aName);
325   end;
326  
327   function TFB30Attachment.StartTransaction(TPB: ITPB;
328 <  DefaultCompletion: TTransactionCompletion): ITransaction;
328 >  DefaultCompletion: TTransactionCompletion; aName: AnsiString): ITransaction;
329   begin
330    CheckHandle;
331 <  Result := TFB30Transaction.Create(FFirebird30ClientAPI,self,TPB,DefaultCompletion);
331 >  Result := TFB30Transaction.Create(FFirebird30ClientAPI,self,TPB,DefaultCompletion,aName);
332   end;
333  
334   procedure TFB30Attachment.ExecImmediate(transaction: ITransaction; sql: AnsiString;

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines