unit AuthAws;

interface

type

HCkString = Pointer;
HCkAuthAws = Pointer;


function CkAuthAws_Create: HCkAuthAws;  stdcall;
procedure CkAuthAws_Dispose(handle: HCkAuthAws); stdcall;
procedure CkAuthAws_getAccessKey(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putAccessKey(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__accessKey(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getCanonicalizedResourceV2(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putCanonicalizedResourceV2(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__canonicalizedResourceV2(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getDebugLogFilePath(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putDebugLogFilePath(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__debugLogFilePath(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getLastErrorHtml(objHandle: HCkAuthAws; outPropVal: HCkString);
function CkAuthAws__lastErrorHtml(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getLastErrorText(objHandle: HCkAuthAws; outPropVal: HCkString);
function CkAuthAws__lastErrorText(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getLastErrorXml(objHandle: HCkAuthAws; outPropVal: HCkString);
function CkAuthAws__lastErrorXml(objHandle: HCkAuthAws): PWideChar;
function CkAuthAws_getLastMethodSuccess(objHandle: HCkAuthAws): wordbool;
procedure CkAuthAws_putLastMethodSuccess(objHandle: HCkAuthAws; newPropVal: wordbool);
procedure CkAuthAws_getPrecomputedMd5(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putPrecomputedMd5(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__precomputedMd5(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getPrecomputedSha256(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putPrecomputedSha256(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__precomputedSha256(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getRegion(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putRegion(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__region(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getSecretKey(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putSecretKey(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__secretKey(objHandle: HCkAuthAws): PWideChar;
procedure CkAuthAws_getServiceName(objHandle: HCkAuthAws; outPropVal: HCkString);
procedure CkAuthAws_putServiceName(objHandle: HCkAuthAws; newPropVal: PWideChar);
function CkAuthAws__serviceName(objHandle: HCkAuthAws): PWideChar;
function CkAuthAws_getSignatureVersion(objHandle: HCkAuthAws): Integer;
procedure CkAuthAws_putSignatureVersion(objHandle: HCkAuthAws; newPropVal: Integer);
function CkAuthAws_getVerboseLogging(objHandle: HCkAuthAws): wordbool;
procedure CkAuthAws_putVerboseLogging(objHandle: HCkAuthAws; newPropVal: wordbool);
procedure CkAuthAws_getVersion(objHandle: HCkAuthAws; outPropVal: HCkString);
function CkAuthAws__version(objHandle: HCkAuthAws): PWideChar;
function CkAuthAws_GenPresignedUrl(objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar; outStr: HCkString): wordbool;
function CkAuthAws__genPresignedUrl(objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar): PWideChar;
implementation

      // Delphi7
{$IF Compilerversion = 15}
      uses Windows, SysUtils, ckDllLoader;
{$ELSE}
      uses Winapi.Windows, System.SysUtils, ckDllLoader;
{$IFEND}

Type
  TCkAuthAws_Create = function : HCkAuthAws; stdcall;
  TCkAuthAws_Dispose = procedure (handle: HCkAuthAws); stdcall;
  TCkAuthAws_getAccessKey = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putAccessKey = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__accessKey = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getCanonicalizedResourceV2 = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putCanonicalizedResourceV2 = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__canonicalizedResourceV2 = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getDebugLogFilePath = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putDebugLogFilePath = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__debugLogFilePath = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getLastErrorHtml = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws__lastErrorHtml = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getLastErrorText = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws__lastErrorText = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getLastErrorXml = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws__lastErrorXml = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getLastMethodSuccess = function (objHandle: HCkAuthAws): wordbool; stdcall;
  TCkAuthAws_putLastMethodSuccess = procedure (objHandle: HCkAuthAws; newPropVal: wordbool); stdcall;
  TCkAuthAws_getPrecomputedMd5 = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putPrecomputedMd5 = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__precomputedMd5 = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getPrecomputedSha256 = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putPrecomputedSha256 = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__precomputedSha256 = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getRegion = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putRegion = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__region = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getSecretKey = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putSecretKey = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__secretKey = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getServiceName = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws_putServiceName = procedure (objHandle: HCkAuthAws; newPropVal: PWideChar); stdcall;
  TCkAuthAws__serviceName = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_getSignatureVersion = function (objHandle: HCkAuthAws): Integer; stdcall;
  TCkAuthAws_putSignatureVersion = procedure (objHandle: HCkAuthAws; newPropVal: Integer); stdcall;
  TCkAuthAws_getVerboseLogging = function (objHandle: HCkAuthAws): wordbool; stdcall;
  TCkAuthAws_putVerboseLogging = procedure (objHandle: HCkAuthAws; newPropVal: wordbool); stdcall;
  TCkAuthAws_getVersion = procedure (objHandle: HCkAuthAws; outPropVal: HCkString); stdcall;
  TCkAuthAws__version = function (objHandle: HCkAuthAws): PWideChar; stdcall;
  TCkAuthAws_GenPresignedUrl = function (objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar; outStr: HCkString): wordbool; stdcall;
  TCkAuthAws__genPresignedUrl = function (objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar): PWideChar; stdcall;

var
  _fkt_ptr_arr:   array [0..41] of Pointer;

function _Map( k:Integer; n:String):Pointer;
begin
  Result:=  _fkt_ptr_arr[k];
  if Result = nil then begin
    Chilkat_GetProcedureAddress(Result, n);
    _fkt_ptr_arr[k]:=   Result;
  end;
end;


function CkAuthAws_Create : HCkAuthAws;
begin
  result := TCkAuthAws_Create(_map(0, 'CkAuthAws_Create'));
end;

procedure CkAuthAws_Dispose (handle: HCkAuthAws);
begin
  TCkAuthAws_Dispose(_map(1, 'CkAuthAws_Dispose'))
    (handle);
end;


procedure CkAuthAws_getAccessKey (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getAccessKey(_map(2, 'CkAuthAws_getAccessKey'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putAccessKey (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putAccessKey(_map(3, 'CkAuthAws_putAccessKey'))
    (objHandle, newPropVal);
end;

function CkAuthAws__accessKey (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__accessKey(_map(4, 'CkAuthAws__accessKey'))
    (objHandle);
end;

procedure CkAuthAws_getCanonicalizedResourceV2 (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getCanonicalizedResourceV2(_map(5, 'CkAuthAws_getCanonicalizedResourceV2'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putCanonicalizedResourceV2 (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putCanonicalizedResourceV2(_map(6, 'CkAuthAws_putCanonicalizedResourceV2'))
    (objHandle, newPropVal);
end;

function CkAuthAws__canonicalizedResourceV2 (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__canonicalizedResourceV2(_map(7, 'CkAuthAws__canonicalizedResourceV2'))
    (objHandle);
end;

procedure CkAuthAws_getDebugLogFilePath (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getDebugLogFilePath(_map(8, 'CkAuthAws_getDebugLogFilePath'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putDebugLogFilePath (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putDebugLogFilePath(_map(9, 'CkAuthAws_putDebugLogFilePath'))
    (objHandle, newPropVal);
end;

function CkAuthAws__debugLogFilePath (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__debugLogFilePath(_map(10, 'CkAuthAws__debugLogFilePath'))
    (objHandle);
end;

procedure CkAuthAws_getLastErrorHtml (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getLastErrorHtml(_map(11, 'CkAuthAws_getLastErrorHtml'))
    (objHandle, outPropVal);
end;

function CkAuthAws__lastErrorHtml (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__lastErrorHtml(_map(12, 'CkAuthAws__lastErrorHtml'))
    (objHandle);
end;

procedure CkAuthAws_getLastErrorText (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getLastErrorText(_map(13, 'CkAuthAws_getLastErrorText'))
    (objHandle, outPropVal);
end;

function CkAuthAws__lastErrorText (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__lastErrorText(_map(14, 'CkAuthAws__lastErrorText'))
    (objHandle);
end;

procedure CkAuthAws_getLastErrorXml (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getLastErrorXml(_map(15, 'CkAuthAws_getLastErrorXml'))
    (objHandle, outPropVal);
end;

function CkAuthAws__lastErrorXml (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__lastErrorXml(_map(16, 'CkAuthAws__lastErrorXml'))
    (objHandle);
end;

function CkAuthAws_getLastMethodSuccess (objHandle: HCkAuthAws): wordbool;
begin
    result := TCkAuthAws_getLastMethodSuccess(_map(17, 'CkAuthAws_getLastMethodSuccess'))
    (objHandle);
end;

procedure CkAuthAws_putLastMethodSuccess (objHandle: HCkAuthAws; newPropVal: wordbool);
begin
  TCkAuthAws_putLastMethodSuccess(_map(18, 'CkAuthAws_putLastMethodSuccess'))
    (objHandle, newPropVal);
end;

procedure CkAuthAws_getPrecomputedMd5 (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getPrecomputedMd5(_map(19, 'CkAuthAws_getPrecomputedMd5'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putPrecomputedMd5 (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putPrecomputedMd5(_map(20, 'CkAuthAws_putPrecomputedMd5'))
    (objHandle, newPropVal);
end;

function CkAuthAws__precomputedMd5 (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__precomputedMd5(_map(21, 'CkAuthAws__precomputedMd5'))
    (objHandle);
end;

procedure CkAuthAws_getPrecomputedSha256 (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getPrecomputedSha256(_map(22, 'CkAuthAws_getPrecomputedSha256'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putPrecomputedSha256 (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putPrecomputedSha256(_map(23, 'CkAuthAws_putPrecomputedSha256'))
    (objHandle, newPropVal);
end;

function CkAuthAws__precomputedSha256 (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__precomputedSha256(_map(24, 'CkAuthAws__precomputedSha256'))
    (objHandle);
end;

procedure CkAuthAws_getRegion (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getRegion(_map(25, 'CkAuthAws_getRegion'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putRegion (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putRegion(_map(26, 'CkAuthAws_putRegion'))
    (objHandle, newPropVal);
end;

function CkAuthAws__region (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__region(_map(27, 'CkAuthAws__region'))
    (objHandle);
end;

procedure CkAuthAws_getSecretKey (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getSecretKey(_map(28, 'CkAuthAws_getSecretKey'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putSecretKey (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putSecretKey(_map(29, 'CkAuthAws_putSecretKey'))
    (objHandle, newPropVal);
end;

function CkAuthAws__secretKey (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__secretKey(_map(30, 'CkAuthAws__secretKey'))
    (objHandle);
end;

procedure CkAuthAws_getServiceName (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getServiceName(_map(31, 'CkAuthAws_getServiceName'))
    (objHandle, outPropVal);
end;

procedure CkAuthAws_putServiceName (objHandle: HCkAuthAws; newPropVal: PWideChar);
begin
  TCkAuthAws_putServiceName(_map(32, 'CkAuthAws_putServiceName'))
    (objHandle, newPropVal);
end;

function CkAuthAws__serviceName (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__serviceName(_map(33, 'CkAuthAws__serviceName'))
    (objHandle);
end;

function CkAuthAws_getSignatureVersion (objHandle: HCkAuthAws): Integer;
begin
    result := TCkAuthAws_getSignatureVersion(_map(34, 'CkAuthAws_getSignatureVersion'))
    (objHandle);
end;

procedure CkAuthAws_putSignatureVersion (objHandle: HCkAuthAws; newPropVal: Integer);
begin
  TCkAuthAws_putSignatureVersion(_map(35, 'CkAuthAws_putSignatureVersion'))
    (objHandle, newPropVal);
end;

function CkAuthAws_getVerboseLogging (objHandle: HCkAuthAws): wordbool;
begin
    result := TCkAuthAws_getVerboseLogging(_map(36, 'CkAuthAws_getVerboseLogging'))
    (objHandle);
end;

procedure CkAuthAws_putVerboseLogging (objHandle: HCkAuthAws; newPropVal: wordbool);
begin
  TCkAuthAws_putVerboseLogging(_map(37, 'CkAuthAws_putVerboseLogging'))
    (objHandle, newPropVal);
end;

procedure CkAuthAws_getVersion (objHandle: HCkAuthAws; outPropVal: HCkString);
begin
  TCkAuthAws_getVersion(_map(38, 'CkAuthAws_getVersion'))
    (objHandle, outPropVal);
end;

function CkAuthAws__version (objHandle: HCkAuthAws): PWideChar;
begin
  result := TCkAuthAws__version(_map(39, 'CkAuthAws__version'))
    (objHandle);
end;

function CkAuthAws_GenPresignedUrl (objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar; outStr: HCkString): wordbool;
begin
  result := TCkAuthAws_GenPresignedUrl(_map(40, 'CkAuthAws_GenPresignedUrl'))
    (objHandle, httpVerb, useHttps, domain, path, numSecondsValid, awsService, outStr);
end;

function CkAuthAws__genPresignedUrl (objHandle: HCkAuthAws; httpVerb: PWideChar; useHttps: wordbool; domain: PWideChar; path: PWideChar; numSecondsValid: Integer; awsService: PWideChar): PWideChar;
begin
  result := TCkAuthAws__genPresignedUrl(_map(41, 'CkAuthAws__genPresignedUrl'))
    (objHandle, httpVerb, useHttps, domain, path, numSecondsValid, awsService);
end;

end.
