//************************************************************************/
// [Caution]: this sample is a demo how to install ePass1000 driver and middleware,
//***********************************************************************/
unit epsSetupApi;

interface
uses
    windows,Classes;
const
//return value used by the deletefile notify callback function.
    NOTIFY_DELETEFILE_REBOOT    =1;
    NOTIFY_DELETEFILE_RETRY	=2;
    NOTIFY_DELETEFILE_CANCEL	=3;
type



    TDeleteFileNotify = function(strMsg:PChar):DWORD;stdcall;
    TShowMsgNotify = procedure(strMsg:PChar);stdcall;

    procedure esa_drv_SetDeleteFileCallback(fNotify:TDeleteFileNotify);stdcall;external 'ePsInst_drv.dll' name 'esa_SetDeleteFileCallback';
    procedure esa_drv_SetShowMsgNotifyCallback(fNotify:TShowMsgNotify);stdcall;external 'ePsInst_drv.dll' name 'esa_SetShowMsgNotifyCallback';
    procedure esa_drv_SetShowErrMsgNotifyCallback(fNotify:TShowMsgNotify);stdcall;external 'ePsInst_drv.dll' name 'esa_SetShowErrMsgNotifyCallback';

    function esa_drv_DoInstall(strPram:string):boolean;stdcall;external 'ePsInst_drv.dll' name 'esa_DoInstall';
    function esa_drv_DoUninstall(strPram:string):boolean;stdcall;external 'ePsInst_drv.dll' name 'esa_DoUninstall';
    function esa_drv_IsNeedReboot():boolean;stdcall;external 'ePsInst_drv.dll' name 'esa_IsNeedReboot';

    procedure esa_mw_SetDeleteFileCallback(fNotify:TDeleteFileNotify);stdcall;external 'ePsInst_Mw.dll' name 'esa_SetDeleteFileCallback';
    procedure esa_mw_SetShowMsgNotifyCallback(fNotify:TShowMsgNotify);stdcall;external 'ePsInst_Mw.dll' name 'esa_SetShowMsgNotifyCallback';
    procedure esa_mw_SetShowErrMsgNotifyCallback(fNotify:TShowMsgNotify);stdcall;external 'ePsInst_Mw.dll' name 'esa_SetShowErrMsgNotifyCallback';

    function esa_mw_DoInstall(strPram:string):boolean;stdcall;external 'ePsInst_Mw.dll' name 'esa_DoInstall';
    function esa_mw_DoUninstall(strPram:string):boolean;stdcall;external 'ePsInst_Mw.dll' name 'esa_DoUninstall';
    function esa_mw_IsNeedReboot():boolean;stdcall;external 'ePsInst_Mw.dll' name 'esa_IsNeedReboot';

implementation

end.
