unit Chilkat.SCard;

{
  Pascal wrapper for Chilkat SCard.
  Auto-generated by PascalWrapperGenerator -- do not edit manually.
}

{$IFDEF FPC}
  {$MODE DELPHI}
{$ENDIF}

interface

uses
  SysUtils,
  Chilkat.Base;

type

  { TSCard wraps CkSCard via the C bridge layer. }
  TSCard = class(TChilkatBase)
  private
    FOnAbortCheck: TChilkatAbortCheckEvent;
    FOnPercentDone: TChilkatPercentDoneEvent;
    FOnProgressInfo: TChilkatProgressInfoEvent;
    function  GetLastErrorHtml: string;
    function  GetLastErrorText: string;
    function  GetLastErrorXml: string;
    function  GetVersion: string;
    function  GetDebugLogFilePath: string;
    procedure SetDebugLogFilePath(AValue: string);
    function  GetVerboseLogging: Boolean;
    procedure SetVerboseLogging(AValue: Boolean);
    function  GetLastMethodSuccess: Boolean;
    procedure SetLastMethodSuccess(AValue: Boolean);
    function  GetContext: string;
    function  GetConnectedReader: string;
    function  GetActiveProtocol: string;
    function  GetReaderStatus: string;
    function  GetCardAtr: string;
    function  GetScardError: string;
    function  GetPcscLibPath: string;
    procedure SetPcscLibPath(AValue: string);
    procedure SetOnAbortCheck(AValue: TChilkatAbortCheckEvent);
    procedure SetOnPercentDone(AValue: TChilkatPercentDoneEvent);
    procedure SetOnProgressInfo(AValue: TChilkatProgressInfoEvent);
  public
    constructor Create;
    destructor  Destroy; override;

    property LastErrorHtml: string read GetLastErrorHtml;
    property LastErrorText: string read GetLastErrorText;
    property LastErrorXml: string read GetLastErrorXml;
    property Version: string read GetVersion;
    property DebugLogFilePath: string read GetDebugLogFilePath write SetDebugLogFilePath;
    property VerboseLogging: Boolean read GetVerboseLogging write SetVerboseLogging;
    property LastMethodSuccess: Boolean read GetLastMethodSuccess write SetLastMethodSuccess;
    property Context: string read GetContext;
    property ConnectedReader: string read GetConnectedReader;
    property ActiveProtocol: string read GetActiveProtocol;
    property ReaderStatus: string read GetReaderStatus;
    property CardAtr: string read GetCardAtr;
    property ScardError: string read GetScardError;
    property PcscLibPath: string read GetPcscLibPath write SetPcscLibPath;

    { Event callbacks.  Return True from OnAbortCheck / OnPercentDone
      to abort the running method.  Callbacks are invoked on the
      thread that called the Chilkat method.  The HeartbeatMs
      property controls the AbortCheck frequency. }
    property OnAbortCheck: TChilkatAbortCheckEvent read FOnAbortCheck write SetOnAbortCheck;
    property OnPercentDone: TChilkatPercentDoneEvent read FOnPercentDone write SetOnPercentDone;
    property OnProgressInfo: TChilkatProgressInfoEvent read FOnProgressInfo write SetOnProgressInfo;

    function  EstablishContext(const scope: string): Boolean;
    function  ReleaseContext: Boolean;
    function  ListReaders(st: TChilkatBase): Boolean;
    function  Connect(const reader: string; const shareMode: string; const preferredProtocol: string): Boolean;
    function  Disconnect(const disposition: string): Boolean;
    function  CheckStatus: Boolean;
    function  Reconnect(const shareMode: string; const preferredProtocol: string; const action: string): Boolean;
    function  GetStatusChange(maxWaitMs: Integer; stReaderNames: TChilkatBase; json: TChilkatBase): Boolean;
    function  GetStatusChangeCancel: Boolean;
    function  Transmit(const protocol: string; bdSend: TChilkatBase; bdRecv: TChilkatBase; maxRecvLen: Integer): Boolean;
    function  BeginTransaction: Boolean;
    function  EndTransaction(const disposition: string): Boolean;
    function  TransmitHex(const protocol: string; const apduHex: string; bdRecv: TChilkatBase; maxRecvLen: Integer): Boolean;
    function  SendControl(controlCode: LongWord; bdSend: TChilkatBase; bdRecv: TChilkatBase): Boolean;
    function  SendControlHex(controlCode: LongWord; const sendData: string; bdRecv: TChilkatBase): Boolean;
    function  GetAttrib(const attr: string; bd: TChilkatBase): Boolean;
    function  GetAttribStr(const attr: string): string;
    function  GetAttribUint(const attr: string): LongWord;
    function  ListReaderGroups(readerGroups: TChilkatBase): Boolean;
    function  FindSmartcards(json: TChilkatBase): Boolean;
  end;

implementation

uses
  CkDllLoader,
  Chilkat.Utils;

{ ---- C bridge function pointer types ---- }
type
  TCkSCard_Create  = function(): Pointer; cdecl;
  TCkSCard_Dispose = procedure(handle: Pointer); cdecl;
  TCkBridgeAbortCheckCb   = function(userData: Pointer): Integer; cdecl;
  TCkBridgePercentDoneCb  = function(pctDone: Integer; userData: Pointer): Integer; cdecl;
  TCkBridgeProgressInfoCb = procedure(name: PAnsiChar; value: PAnsiChar; userData: Pointer); cdecl;
  TCkSCard_SetAbortCheckCallback   = procedure(handle: Pointer; cb: TCkBridgeAbortCheckCb; userData: Pointer); cdecl;
  TCkSCard_SetPercentDoneCallback  = procedure(handle: Pointer; cb: TCkBridgePercentDoneCb; userData: Pointer); cdecl;
  TCkSCard_SetProgressInfoCallback = procedure(handle: Pointer; cb: TCkBridgeProgressInfoCb; userData: Pointer); cdecl;
  TCkSCard_get_LastErrorHtml = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_LastErrorText = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_LastErrorXml = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_Version = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_DebugLogFilePath = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_put_DebugLogFilePath = procedure(handle: Pointer; value: PAnsiChar); cdecl;
  TCkSCard_get_VerboseLogging = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_put_VerboseLogging = procedure(handle: Pointer; value: LongBool); cdecl;
  TCkSCard_get_LastMethodSuccess = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_put_LastMethodSuccess = procedure(handle: Pointer; value: LongBool); cdecl;
  TCkSCard_get_Context = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_ConnectedReader = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_ActiveProtocol = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_ReaderStatus = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_CardAtr = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_ScardError = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_get_PcscLibPath = function(handle: Pointer): PAnsiChar; cdecl;
  TCkSCard_put_PcscLibPath = procedure(handle: Pointer; value: PAnsiChar); cdecl;
  TCkSCard_EstablishContext = function(handle: Pointer; scope: PAnsiChar): LongBool; cdecl;
  TCkSCard_ReleaseContext = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_ListReaders = function(handle: Pointer; st: Pointer): LongBool; cdecl;
  TCkSCard_Connect = function(handle: Pointer; reader: PAnsiChar; shareMode: PAnsiChar; preferredProtocol: PAnsiChar): LongBool; cdecl;
  TCkSCard_Disconnect = function(handle: Pointer; disposition: PAnsiChar): LongBool; cdecl;
  TCkSCard_CheckStatus = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_Reconnect = function(handle: Pointer; shareMode: PAnsiChar; preferredProtocol: PAnsiChar; action: PAnsiChar): LongBool; cdecl;
  TCkSCard_GetStatusChange = function(handle: Pointer; maxWaitMs: Integer; stReaderNames: Pointer; json: Pointer): LongBool; cdecl;
  TCkSCard_GetStatusChangeCancel = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_Transmit = function(handle: Pointer; protocol: PAnsiChar; bdSend: Pointer; bdRecv: Pointer; maxRecvLen: Integer): LongBool; cdecl;
  TCkSCard_BeginTransaction = function(handle: Pointer): LongBool; cdecl;
  TCkSCard_EndTransaction = function(handle: Pointer; disposition: PAnsiChar): LongBool; cdecl;
  TCkSCard_TransmitHex = function(handle: Pointer; protocol: PAnsiChar; apduHex: PAnsiChar; bdRecv: Pointer; maxRecvLen: Integer): LongBool; cdecl;
  TCkSCard_SendControl = function(handle: Pointer; controlCode: LongWord; bdSend: Pointer; bdRecv: Pointer): LongBool; cdecl;
  TCkSCard_SendControlHex = function(handle: Pointer; controlCode: LongWord; sendData: PAnsiChar; bdRecv: Pointer): LongBool; cdecl;
  TCkSCard_GetAttrib = function(handle: Pointer; attr: PAnsiChar; bd: Pointer): LongBool; cdecl;
  TCkSCard_GetAttribStr = function(handle: Pointer; attr: PAnsiChar): PAnsiChar; cdecl;
  TCkSCard_GetAttribUint = function(handle: Pointer; attr: PAnsiChar): LongWord; cdecl;
  TCkSCard_ListReaderGroups = function(handle: Pointer; readerGroups: Pointer): LongBool; cdecl;
  TCkSCard_FindSmartcards = function(handle: Pointer; json: Pointer): LongBool; cdecl;

{ ---- C bridge function pointer variables ---- }
var
  CkSCard_Create:  TCkSCard_Create  = nil;
  CkSCard_Dispose: TCkSCard_Dispose = nil;
  CkSCard_SetAbortCheckCallback:   TCkSCard_SetAbortCheckCallback   = nil;
  CkSCard_SetPercentDoneCallback:  TCkSCard_SetPercentDoneCallback  = nil;
  CkSCard_SetProgressInfoCallback: TCkSCard_SetProgressInfoCallback = nil;
  CkSCard_get_LastErrorHtml: TCkSCard_get_LastErrorHtml = nil;
  CkSCard_get_LastErrorText: TCkSCard_get_LastErrorText = nil;
  CkSCard_get_LastErrorXml: TCkSCard_get_LastErrorXml = nil;
  CkSCard_get_Version: TCkSCard_get_Version = nil;
  CkSCard_get_DebugLogFilePath: TCkSCard_get_DebugLogFilePath = nil;
  CkSCard_put_DebugLogFilePath: TCkSCard_put_DebugLogFilePath = nil;
  CkSCard_get_VerboseLogging: TCkSCard_get_VerboseLogging = nil;
  CkSCard_put_VerboseLogging: TCkSCard_put_VerboseLogging = nil;
  CkSCard_get_LastMethodSuccess: TCkSCard_get_LastMethodSuccess = nil;
  CkSCard_put_LastMethodSuccess: TCkSCard_put_LastMethodSuccess = nil;
  CkSCard_get_Context: TCkSCard_get_Context = nil;
  CkSCard_get_ConnectedReader: TCkSCard_get_ConnectedReader = nil;
  CkSCard_get_ActiveProtocol: TCkSCard_get_ActiveProtocol = nil;
  CkSCard_get_ReaderStatus: TCkSCard_get_ReaderStatus = nil;
  CkSCard_get_CardAtr: TCkSCard_get_CardAtr = nil;
  CkSCard_get_ScardError: TCkSCard_get_ScardError = nil;
  CkSCard_get_PcscLibPath: TCkSCard_get_PcscLibPath = nil;
  CkSCard_put_PcscLibPath: TCkSCard_put_PcscLibPath = nil;
  CkSCard_EstablishContext: TCkSCard_EstablishContext = nil;
  CkSCard_ReleaseContext: TCkSCard_ReleaseContext = nil;
  CkSCard_ListReaders: TCkSCard_ListReaders = nil;
  CkSCard_Connect: TCkSCard_Connect = nil;
  CkSCard_Disconnect: TCkSCard_Disconnect = nil;
  CkSCard_CheckStatus: TCkSCard_CheckStatus = nil;
  CkSCard_Reconnect: TCkSCard_Reconnect = nil;
  CkSCard_GetStatusChange: TCkSCard_GetStatusChange = nil;
  CkSCard_GetStatusChangeCancel: TCkSCard_GetStatusChangeCancel = nil;
  CkSCard_Transmit: TCkSCard_Transmit = nil;
  CkSCard_BeginTransaction: TCkSCard_BeginTransaction = nil;
  CkSCard_EndTransaction: TCkSCard_EndTransaction = nil;
  CkSCard_TransmitHex: TCkSCard_TransmitHex = nil;
  CkSCard_SendControl: TCkSCard_SendControl = nil;
  CkSCard_SendControlHex: TCkSCard_SendControlHex = nil;
  CkSCard_GetAttrib: TCkSCard_GetAttrib = nil;
  CkSCard_GetAttribStr: TCkSCard_GetAttribStr = nil;
  CkSCard_GetAttribUint: TCkSCard_GetAttribUint = nil;
  CkSCard_ListReaderGroups: TCkSCard_ListReaderGroups = nil;
  CkSCard_FindSmartcards: TCkSCard_FindSmartcards = nil;

constructor TSCard.Create;
begin
  inherited Create;
  FHandle := CkSCard_Create();
end;

destructor TSCard.Destroy;
begin
  if FHandle <> nil then
    CkSCard_Dispose(FHandle);
  FHandle := nil;
  inherited;
end;

{ ---- Event callback thunks ---- }
{ Standalone cdecl functions registered with the C bridge.  The bridge
  passes back the userData pointer, which carries the Pascal object
  instance.  A non-zero return value aborts the running method. }

function TSCard_AbortCheckThunk(userData: Pointer): Integer; cdecl;
var
  obj: TSCard;
begin
  Result := 0;
  obj := TSCard(userData);
  if Assigned(obj) and Assigned(obj.FOnAbortCheck) then
    if obj.FOnAbortCheck(obj) then Result := 1;
end;

function TSCard_PercentDoneThunk(pctDone: Integer; userData: Pointer): Integer; cdecl;
var
  obj: TSCard;
begin
  Result := 0;
  obj := TSCard(userData);
  if Assigned(obj) and Assigned(obj.FOnPercentDone) then
    if obj.FOnPercentDone(obj, pctDone) then Result := 1;
end;

procedure TSCard_ProgressInfoThunk(name: PAnsiChar; value: PAnsiChar; userData: Pointer); cdecl;
var
  obj: TSCard;
begin
  obj := TSCard(userData);
  if Assigned(obj) and Assigned(obj.FOnProgressInfo) then
    obj.FOnProgressInfo(obj, CkToStr(name), CkToStr(value));
end;

procedure TSCard.SetOnAbortCheck(AValue: TChilkatAbortCheckEvent);
begin
  FOnAbortCheck := AValue;
  if Assigned(AValue) then
    CkSCard_SetAbortCheckCallback(FHandle, @TSCard_AbortCheckThunk, Self)
  else
    CkSCard_SetAbortCheckCallback(FHandle, nil, nil);
end;

procedure TSCard.SetOnPercentDone(AValue: TChilkatPercentDoneEvent);
begin
  FOnPercentDone := AValue;
  if Assigned(AValue) then
    CkSCard_SetPercentDoneCallback(FHandle, @TSCard_PercentDoneThunk, Self)
  else
    CkSCard_SetPercentDoneCallback(FHandle, nil, nil);
end;

procedure TSCard.SetOnProgressInfo(AValue: TChilkatProgressInfoEvent);
begin
  FOnProgressInfo := AValue;
  if Assigned(AValue) then
    CkSCard_SetProgressInfoCallback(FHandle, @TSCard_ProgressInfoThunk, Self)
  else
    CkSCard_SetProgressInfoCallback(FHandle, nil, nil);
end;

function TSCard.GetLastErrorHtml: string;
begin
  Result := CkToStr(CkSCard_get_LastErrorHtml(FHandle));
end;

function TSCard.GetLastErrorText: string;
begin
  Result := CkToStr(CkSCard_get_LastErrorText(FHandle));
end;

function TSCard.GetLastErrorXml: string;
begin
  Result := CkToStr(CkSCard_get_LastErrorXml(FHandle));
end;

function TSCard.GetVersion: string;
begin
  Result := CkToStr(CkSCard_get_Version(FHandle));
end;

function TSCard.GetDebugLogFilePath: string;
begin
  Result := CkToStr(CkSCard_get_DebugLogFilePath(FHandle));
end;

procedure TSCard.SetDebugLogFilePath(AValue: string);
begin
  CkSCard_put_DebugLogFilePath(FHandle, PAnsiChar(StrToCk(AValue)));
end;

function TSCard.GetVerboseLogging: Boolean;
begin
  Result := Boolean(CkSCard_get_VerboseLogging(FHandle));
end;

procedure TSCard.SetVerboseLogging(AValue: Boolean);
begin
  CkSCard_put_VerboseLogging(FHandle, LongBool(AValue));
end;

function TSCard.GetLastMethodSuccess: Boolean;
begin
  Result := Boolean(CkSCard_get_LastMethodSuccess(FHandle));
end;

procedure TSCard.SetLastMethodSuccess(AValue: Boolean);
begin
  CkSCard_put_LastMethodSuccess(FHandle, LongBool(AValue));
end;

function TSCard.GetContext: string;
begin
  Result := CkToStr(CkSCard_get_Context(FHandle));
end;

function TSCard.GetConnectedReader: string;
begin
  Result := CkToStr(CkSCard_get_ConnectedReader(FHandle));
end;

function TSCard.GetActiveProtocol: string;
begin
  Result := CkToStr(CkSCard_get_ActiveProtocol(FHandle));
end;

function TSCard.GetReaderStatus: string;
begin
  Result := CkToStr(CkSCard_get_ReaderStatus(FHandle));
end;

function TSCard.GetCardAtr: string;
begin
  Result := CkToStr(CkSCard_get_CardAtr(FHandle));
end;

function TSCard.GetScardError: string;
begin
  Result := CkToStr(CkSCard_get_ScardError(FHandle));
end;

function TSCard.GetPcscLibPath: string;
begin
  Result := CkToStr(CkSCard_get_PcscLibPath(FHandle));
end;

procedure TSCard.SetPcscLibPath(AValue: string);
begin
  CkSCard_put_PcscLibPath(FHandle, PAnsiChar(StrToCk(AValue)));
end;

function TSCard.EstablishContext(const scope: string): Boolean;
begin
  Result := Boolean(CkSCard_EstablishContext(FHandle, PAnsiChar(StrToCk(scope))));
end;

function TSCard.ReleaseContext: Boolean;
begin
  Result := Boolean(CkSCard_ReleaseContext(FHandle));
end;

function TSCard.ListReaders(st: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_ListReaders(FHandle, st.Handle));
end;

function TSCard.Connect(const reader: string; const shareMode: string; const preferredProtocol: string): Boolean;
begin
  Result := Boolean(CkSCard_Connect(FHandle, PAnsiChar(StrToCk(reader)), PAnsiChar(StrToCk(shareMode)), PAnsiChar(StrToCk(preferredProtocol))));
end;

function TSCard.Disconnect(const disposition: string): Boolean;
begin
  Result := Boolean(CkSCard_Disconnect(FHandle, PAnsiChar(StrToCk(disposition))));
end;

function TSCard.CheckStatus: Boolean;
begin
  Result := Boolean(CkSCard_CheckStatus(FHandle));
end;

function TSCard.Reconnect(const shareMode: string; const preferredProtocol: string; const action: string): Boolean;
begin
  Result := Boolean(CkSCard_Reconnect(FHandle, PAnsiChar(StrToCk(shareMode)), PAnsiChar(StrToCk(preferredProtocol)), PAnsiChar(StrToCk(action))));
end;

function TSCard.GetStatusChange(maxWaitMs: Integer; stReaderNames: TChilkatBase; json: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_GetStatusChange(FHandle, maxWaitMs, stReaderNames.Handle, json.Handle));
end;

function TSCard.GetStatusChangeCancel: Boolean;
begin
  Result := Boolean(CkSCard_GetStatusChangeCancel(FHandle));
end;

function TSCard.Transmit(const protocol: string; bdSend: TChilkatBase; bdRecv: TChilkatBase; maxRecvLen: Integer): Boolean;
begin
  Result := Boolean(CkSCard_Transmit(FHandle, PAnsiChar(StrToCk(protocol)), bdSend.Handle, bdRecv.Handle, maxRecvLen));
end;

function TSCard.BeginTransaction: Boolean;
begin
  Result := Boolean(CkSCard_BeginTransaction(FHandle));
end;

function TSCard.EndTransaction(const disposition: string): Boolean;
begin
  Result := Boolean(CkSCard_EndTransaction(FHandle, PAnsiChar(StrToCk(disposition))));
end;

function TSCard.TransmitHex(const protocol: string; const apduHex: string; bdRecv: TChilkatBase; maxRecvLen: Integer): Boolean;
begin
  Result := Boolean(CkSCard_TransmitHex(FHandle, PAnsiChar(StrToCk(protocol)), PAnsiChar(StrToCk(apduHex)), bdRecv.Handle, maxRecvLen));
end;

function TSCard.SendControl(controlCode: LongWord; bdSend: TChilkatBase; bdRecv: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_SendControl(FHandle, controlCode, bdSend.Handle, bdRecv.Handle));
end;

function TSCard.SendControlHex(controlCode: LongWord; const sendData: string; bdRecv: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_SendControlHex(FHandle, controlCode, PAnsiChar(StrToCk(sendData)), bdRecv.Handle));
end;

function TSCard.GetAttrib(const attr: string; bd: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_GetAttrib(FHandle, PAnsiChar(StrToCk(attr)), bd.Handle));
end;

function TSCard.GetAttribStr(const attr: string): string;
begin
  Result := CkToStr(CkSCard_GetAttribStr(FHandle, PAnsiChar(StrToCk(attr))));
end;

function TSCard.GetAttribUint(const attr: string): LongWord;
begin
  Result := CkSCard_GetAttribUint(FHandle, PAnsiChar(StrToCk(attr)));
end;

function TSCard.ListReaderGroups(readerGroups: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_ListReaderGroups(FHandle, readerGroups.Handle));
end;

function TSCard.FindSmartcards(json: TChilkatBase): Boolean;
begin
  Result := Boolean(CkSCard_FindSmartcards(FHandle, json.Handle));
end;

initialization
  Chilkat_GetProcedureAddress(CkSCard_Create,  'CkSCard_Create');
  Chilkat_GetProcedureAddress(CkSCard_Dispose, 'CkSCard_Dispose');
  Chilkat_GetProcedureAddress(CkSCard_SetAbortCheckCallback, 'CkSCard_SetAbortCheckCallback');
  Chilkat_GetProcedureAddress(CkSCard_SetPercentDoneCallback, 'CkSCard_SetPercentDoneCallback');
  Chilkat_GetProcedureAddress(CkSCard_SetProgressInfoCallback, 'CkSCard_SetProgressInfoCallback');
  Chilkat_GetProcedureAddress(CkSCard_get_LastErrorHtml, 'CkSCard_get_LastErrorHtml');
  Chilkat_GetProcedureAddress(CkSCard_get_LastErrorText, 'CkSCard_get_LastErrorText');
  Chilkat_GetProcedureAddress(CkSCard_get_LastErrorXml, 'CkSCard_get_LastErrorXml');
  Chilkat_GetProcedureAddress(CkSCard_get_Version, 'CkSCard_get_Version');
  Chilkat_GetProcedureAddress(CkSCard_get_DebugLogFilePath, 'CkSCard_get_DebugLogFilePath');
  Chilkat_GetProcedureAddress(CkSCard_put_DebugLogFilePath, 'CkSCard_put_DebugLogFilePath');
  Chilkat_GetProcedureAddress(CkSCard_get_VerboseLogging, 'CkSCard_get_VerboseLogging');
  Chilkat_GetProcedureAddress(CkSCard_put_VerboseLogging, 'CkSCard_put_VerboseLogging');
  Chilkat_GetProcedureAddress(CkSCard_get_LastMethodSuccess, 'CkSCard_get_LastMethodSuccess');
  Chilkat_GetProcedureAddress(CkSCard_put_LastMethodSuccess, 'CkSCard_put_LastMethodSuccess');
  Chilkat_GetProcedureAddress(CkSCard_get_Context, 'CkSCard_get_Context');
  Chilkat_GetProcedureAddress(CkSCard_get_ConnectedReader, 'CkSCard_get_ConnectedReader');
  Chilkat_GetProcedureAddress(CkSCard_get_ActiveProtocol, 'CkSCard_get_ActiveProtocol');
  Chilkat_GetProcedureAddress(CkSCard_get_ReaderStatus, 'CkSCard_get_ReaderStatus');
  Chilkat_GetProcedureAddress(CkSCard_get_CardAtr, 'CkSCard_get_CardAtr');
  Chilkat_GetProcedureAddress(CkSCard_get_ScardError, 'CkSCard_get_ScardError');
  Chilkat_GetProcedureAddress(CkSCard_get_PcscLibPath, 'CkSCard_get_PcscLibPath');
  Chilkat_GetProcedureAddress(CkSCard_put_PcscLibPath, 'CkSCard_put_PcscLibPath');
  Chilkat_GetProcedureAddress(CkSCard_EstablishContext, 'CkSCard_EstablishContext');
  Chilkat_GetProcedureAddress(CkSCard_ReleaseContext, 'CkSCard_ReleaseContext');
  Chilkat_GetProcedureAddress(CkSCard_ListReaders, 'CkSCard_ListReaders');
  Chilkat_GetProcedureAddress(CkSCard_Connect, 'CkSCard_Connect');
  Chilkat_GetProcedureAddress(CkSCard_Disconnect, 'CkSCard_Disconnect');
  Chilkat_GetProcedureAddress(CkSCard_CheckStatus, 'CkSCard_CheckStatus');
  Chilkat_GetProcedureAddress(CkSCard_Reconnect, 'CkSCard_Reconnect');
  Chilkat_GetProcedureAddress(CkSCard_GetStatusChange, 'CkSCard_GetStatusChange');
  Chilkat_GetProcedureAddress(CkSCard_GetStatusChangeCancel, 'CkSCard_GetStatusChangeCancel');
  Chilkat_GetProcedureAddress(CkSCard_Transmit, 'CkSCard_Transmit');
  Chilkat_GetProcedureAddress(CkSCard_BeginTransaction, 'CkSCard_BeginTransaction');
  Chilkat_GetProcedureAddress(CkSCard_EndTransaction, 'CkSCard_EndTransaction');
  Chilkat_GetProcedureAddress(CkSCard_TransmitHex, 'CkSCard_TransmitHex');
  Chilkat_GetProcedureAddress(CkSCard_SendControl, 'CkSCard_SendControl');
  Chilkat_GetProcedureAddress(CkSCard_SendControlHex, 'CkSCard_SendControlHex');
  Chilkat_GetProcedureAddress(CkSCard_GetAttrib, 'CkSCard_GetAttrib');
  Chilkat_GetProcedureAddress(CkSCard_GetAttribStr, 'CkSCard_GetAttribStr');
  Chilkat_GetProcedureAddress(CkSCard_GetAttribUint, 'CkSCard_GetAttribUint');
  Chilkat_GetProcedureAddress(CkSCard_ListReaderGroups, 'CkSCard_ListReaderGroups');
  Chilkat_GetProcedureAddress(CkSCard_FindSmartcards, 'CkSCard_FindSmartcards');

end.
