98 |
|
function obtainInfoCode: Integer; |
99 |
|
function getInfo(code: Integer): Pointer; |
100 |
|
function setInfo(code: Integer; value: Pointer): Pointer; |
101 |
+ |
function cloneAttachment: IAttachment; |
102 |
+ |
function GetServiceManager: IServiceManager; |
103 |
|
function HasConfigFile: boolean; |
104 |
|
function ReadConfigString(Section, Ident, DefaultValue: AnsiString): AnsiString; |
105 |
|
function ReadConfigInteger(Section, Ident: AnsiString; DefaultValue: integer): integer; |
282 |
|
|
283 |
|
var i: integer; |
284 |
|
begin |
285 |
< |
Result := Format('Field Count = %d' + NewLineTAB,[getCount]) + |
286 |
< |
Format('Alignment = %d' + NewLineTAB,[getAlignment]) + |
287 |
< |
Format('Aligned Length = %d' + NewLineTAB,[getAlignedLength]); |
285 |
> |
Result := Format('Field Count = %d' + NewLineTAB,[getCount]); |
286 |
> |
if FMetadata.vTable.version >= 4 then |
287 |
> |
begin |
288 |
> |
Result := Result + Format('Alignment = %d' + NewLineTAB,[getAlignment]) + |
289 |
> |
Format('Aligned Length = %d' + NewLineTAB,[getAlignedLength]); |
290 |
> |
end; |
291 |
|
for i := 0 to getCount - 1 do |
292 |
|
begin |
293 |
|
Result := Result + |
296 |
|
Format('Relation Name = %s' + NewLineTAB,[getRelation(i)]) + |
297 |
|
Format('Alias Name = %s' + NewLineTAB,[getAlias(i)]) + |
298 |
|
Format('SQLType = %s' + NewLineTAB,[TSQLDataItem.GetSQLTypeName(getType(i))]) + |
299 |
< |
Format('IsNullable = %s' + NewLineTAB,[BoolToStr(isNullable(i){$ifdef FPC},'yes','no'{$endif})]) + |
299 |
> |
Format('IsNullable = %s' + NewLineTAB,[BooleanToStr(isNullable(i),'yes','no')]) + |
300 |
|
Format('SubType = %d' + NewLineTAB,[getSubType(i)]) + |
301 |
|
Format('Length = %d' + NewLineTAB,[getLength(i)]) + |
302 |
|
Format('Scale = %d' + NewLineTAB,[getScale(i)]) + |
560 |
|
inherited Create(aController); |
561 |
|
FContext := context; |
562 |
|
FirebirdAPI := TFB30ClientAPI.Create(context.getMaster); |
563 |
+ |
aController.StartJournaling(self); |
564 |
|
end; |
565 |
|
|
566 |
|
function TFBUDRExternalContext.AsText: AnsiString; |
635 |
|
Result := FContext.setInfo(code,value); |
636 |
|
end; |
637 |
|
|
638 |
+ |
function TFBUDRExternalContext.cloneAttachment: IAttachment; |
639 |
+ |
var DPB: IDPB; |
640 |
+ |
begin |
641 |
+ |
DPB := GetFirebirdAPI.AllocateDPB; |
642 |
+ |
DPB.Add(isc_dpb_user_name).setAsString(GetUserName); |
643 |
+ |
DPB.Add(isc_dpb_lc_ctype).setAsString(GetClientCharSet); |
644 |
+ |
Result := GetFirebirdAPI.OpenDatabase(GetDatabaseName,DPB); |
645 |
+ |
end; |
646 |
+ |
|
647 |
+ |
function TFBUDRExternalContext.GetServiceManager: IServiceManager; |
648 |
+ |
var SPB: ISPB; |
649 |
+ |
begin |
650 |
+ |
SPB := FirebirdAPI.AllocateSPB; |
651 |
+ |
SPB.Add(isc_spb_user_name).setAsString(GetUserName); |
652 |
+ |
Result := GetFirebirdAPI.GetServiceManager('',Local,SPB); |
653 |
+ |
end; |
654 |
+ |
|
655 |
|
function TFBUDRExternalContext.HasConfigFile: boolean; |
656 |
|
begin |
657 |
|
Result := Controller.HasConfigFile; |
792 |
|
Result := Format('Package Name = %s' + NewLineTAB,[getPackage]) + |
793 |
|
Format('Name = %s' + NewLineTAB,[getName]) + |
794 |
|
Format('Entry Point = %s (%s,%s,%s)' + NewLineTAB,[getEntryPoint,getModuleName,getRoutineName,getInfo]) + |
795 |
< |
Format('Body = %s' + NewLineTAB,[getBody]) + |
796 |
< |
Format('Input Metadata:' + NewLineTAB + '%s',[MetadataToText(FInputMetaData)]) + LineEnding + |
797 |
< |
Format('Output Metadata:' + NewLineTAB + '%s',[MetadataToText(FOutputMetaData)]); |
795 |
> |
Format('Body = %s' + NewLineTAB,[getBody]); |
796 |
> |
if HasInputMetaData then |
797 |
> |
Result := Result + Format('Input Metadata:' + NewLineTAB + '%s',[MetadataToText(FInputMetaData)]) + LineEnding; |
798 |
> |
if HasOutputMetaData then |
799 |
> |
Result := Result + Format('Output Metadata:' + NewLineTAB + '%s',[MetadataToText(FOutputMetaData)]); |
800 |
|
if FRoutineMetadata.getTriggerType(FStatus) > 0 then |
801 |
|
begin |
802 |
+ |
if HasTriggerMetaData then |
803 |
+ |
Result := Result + Format('Trigger Metadata:' + NewLineTAB + '%s',[MetadataToText(FTriggerMetaData)]); |
804 |
|
Result := Result + |
778 |
– |
Format('Trigger Metadata:' + NewLineTAB + '%s',[MetadataToText(FTriggerMetaData)]) + |
805 |
|
Format('Trigger Table = %s' + NewLineTAB,[getTriggerTable]) + |
806 |
|
Format('Trigger Type = %s' + NewLineTAB,[TriggerTypeToText(getTriggerType)]); |
807 |
|
end; |