mirror of
https://github.com/doublecmd/doublecmd.git
synced 2026-06-21 09:58:13 +00:00
ADD: MacCloud/S3: step-110: Huawei OBS
This commit is contained in:
parent
393498aad7
commit
57737f8d98
3 changed files with 54 additions and 2 deletions
|
|
@ -168,6 +168,11 @@
|
|||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="uS3CompatibleClient"/>
|
||||
</Unit>
|
||||
<Unit>
|
||||
<Filename Value="drivers/aws/huaweiobs/uhuaweiobsclient.pas"/>
|
||||
<IsPartOfProject Value="True"/>
|
||||
<UnitName Value="uHuaweiOBSClient"/>
|
||||
</Unit>
|
||||
</Units>
|
||||
</ProjectOptions>
|
||||
<CompilerOptions>
|
||||
|
|
@ -177,7 +182,7 @@
|
|||
</Target>
|
||||
<SearchPaths>
|
||||
<IncludeFiles Value="$(ProjOutDir)"/>
|
||||
<OtherUnitFiles Value="../../../../sdk;util;drivers/root;drivers;drivers/aws;drivers/aws/aliyunoss;drivers/oauth2/box;drivers/oauth2/dropbox;drivers/oauth2/onedrive;drivers/oauth2/yandex;wfx/ui;wfx;drivers/oauth2;drivers/aws/tencentcos;drivers/aws/amazons3;drivers/aws/s3compatible"/>
|
||||
<OtherUnitFiles Value="../../../../sdk;util;drivers/root;drivers;drivers/aws;drivers/aws/aliyunoss;drivers/oauth2/box;drivers/oauth2/dropbox;drivers/oauth2/onedrive;drivers/oauth2/yandex;wfx/ui;wfx;drivers/oauth2;drivers/aws/tencentcos;drivers/aws/amazons3;drivers/aws/s3compatible;drivers/aws/huaweiobs"/>
|
||||
<UnitOutputDirectory Value="../lib/$(TargetCPU)-$(TargetOS)"/>
|
||||
</SearchPaths>
|
||||
<CodeGeneration>
|
||||
|
|
|
|||
|
|
@ -0,0 +1,42 @@
|
|||
unit uHuaweiOBSClient;
|
||||
|
||||
{$mode ObjFPC}{$H+}
|
||||
|
||||
interface
|
||||
|
||||
uses
|
||||
Classes, SysUtils,
|
||||
uCloudDriver, uAWSAuth, uS3Client;
|
||||
|
||||
type
|
||||
|
||||
{ THuaweiOBSClient }
|
||||
|
||||
THuaweiOBSClient = class( TS3Client )
|
||||
public
|
||||
class function driverName: String; override;
|
||||
class function createInstance: TCloudDriver; override;
|
||||
function getConcreteClass: TCloudDriverClass; override;
|
||||
end;
|
||||
|
||||
implementation
|
||||
|
||||
{ THuaweiOBSClient }
|
||||
|
||||
class function THuaweiOBSClient.driverName: String;
|
||||
begin
|
||||
Result:= 'HuaweiOBS';
|
||||
end;
|
||||
|
||||
class function THuaweiOBSClient.createInstance: TCloudDriver;
|
||||
begin
|
||||
Result:= THuaweiOBSClient.Create;
|
||||
end;
|
||||
|
||||
function THuaweiOBSClient.getConcreteClass: TCloudDriverClass;
|
||||
begin
|
||||
Result:= THuaweiOBSClient;
|
||||
end;
|
||||
|
||||
end.
|
||||
|
||||
|
|
@ -11,7 +11,8 @@ uses
|
|||
uWFXPlugin, uCloudDriver,
|
||||
uOAuth2Core, uOAuth2Client, uDropBoxClient, uYandexClient, uOneDriveClient, uBoxClient,
|
||||
uAWSCore, uS3Client,
|
||||
uAmazonS3Client, uS3CompatibleClient, uAliyunOSSClient, uTencentCOSClient,
|
||||
uAmazonS3Client, uS3CompatibleClient,
|
||||
uAliyunOSSClient, uTencentCOSClient, uHuaweiOBSClient,
|
||||
uMiniUtil;
|
||||
|
||||
type
|
||||
|
|
@ -563,6 +564,10 @@ begin
|
|||
WFXCloudDriverConfigManager.register( TTencentCOSClient.driverName, TWFXS3Config );
|
||||
cloudDriverManager.register( TTencentCOSClient );
|
||||
WFXCloudDriverMenuItems.add( TTencentCOSClient.driverName, 'Tencent Cloud COS' );
|
||||
|
||||
WFXCloudDriverConfigManager.register( THuaweiOBSClient.driverName, TWFXS3Config );
|
||||
cloudDriverManager.register( THuaweiOBSClient );
|
||||
WFXCloudDriverMenuItems.add( THuaweiOBSClient.driverName, 'Huawei Cloud OBS' );
|
||||
end;
|
||||
|
||||
initialization
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue