📄 jwalmrepl.pas
字号:
rpid1_lockcount: DWORD;
rpid1_locktime: DWORD;
end;
{$EXTERNALSYM _REPL_IDIR_INFO_1}
REPL_IDIR_INFO_1 = _REPL_IDIR_INFO_1;
{$EXTERNALSYM REPL_IDIR_INFO_1}
LPREPL_IDIR_INFO_1 = ^REPL_IDIR_INFO_1;
{$EXTERNALSYM LPREPL_IDIR_INFO_1}
PREPL_IDIR_INFO_1 = ^REPL_IDIR_INFO_1;
{$EXTERNALSYM PREPL_IDIR_INFO_1}
TReplIdirInfo1 = REPL_IDIR_INFO_1;
PReplIdirInfo1 = PREPL_IDIR_INFO_1;
function NetReplImportDirAdd(servername: LPCWSTR; level: DWORD; buf: LPBYTE; parm_err: LPDWORD): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirAdd}
function NetReplImportDirDel(servername: LPCWSTR; dirname: LPCWSTR): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirDel}
function NetReplImportDirEnum(servername: LPCWSTR; level: DWORD; var bufptr: LPBYTE; prefmaxlen: DWORD; entriesread, totalentries, resumehandle: LPDWORD): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirEnum}
function NetReplImportDirGetInfo(servername, dirname: LPCWSTR; level: DWORD; var bufptr: LPBYTE): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirGetInfo}
function NetReplImportDirLock(servername: LPCWSTR; dirname: LPCWSTR): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirLock}
function NetReplImportDirUnlock(servername: LPCWSTR; dirname: LPCWSTR; unlockforce: DWORD): NET_API_STATUS; stdcall;
{$EXTERNALSYM NetReplImportDirUnlock}
const
REPL_STATE_OK = 0;
{$EXTERNALSYM REPL_STATE_OK}
REPL_STATE_NO_MASTER = 1;
{$EXTERNALSYM REPL_STATE_NO_MASTER}
REPL_STATE_NO_SYNC = 2;
{$EXTERNALSYM REPL_STATE_NO_SYNC}
REPL_STATE_NEVER_REPLICATED = 3;
{$EXTERNALSYM REPL_STATE_NEVER_REPLICATED}
implementation
{$IFDEF DYNAMIC_LINK}
var
_NetReplGetInfo: Pointer;
function NetReplGetInfo;
begin
GetProcedureAddress(_NetReplGetInfo, netapi32, 'NetReplGetInfo');
asm
mov esp, ebp
pop ebp
jmp [_NetReplGetInfo]
end;
end;
{$ELSE}
function NetReplGetInfo; external netapi32 name 'NetReplGetInfo';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplSetInfo: Pointer;
function NetReplSetInfo;
begin
GetProcedureAddress(_NetReplSetInfo, netapi32, 'NetReplSetInfo');
asm
mov esp, ebp
pop ebp
jmp [_NetReplSetInfo]
end;
end;
{$ELSE}
function NetReplSetInfo; external netapi32 name 'NetReplSetInfo';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirAdd: Pointer;
function NetReplExportDirAdd;
begin
GetProcedureAddress(_NetReplExportDirAdd, netapi32, 'NetReplExportDirAdd');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirAdd]
end;
end;
{$ELSE}
function NetReplExportDirAdd; external netapi32 name 'NetReplExportDirAdd';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirDel: Pointer;
function NetReplExportDirDel;
begin
GetProcedureAddress(_NetReplExportDirDel, netapi32, 'NetReplExportDirDel');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirDel]
end;
end;
{$ELSE}
function NetReplExportDirDel; external netapi32 name 'NetReplExportDirDel';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirEnum: Pointer;
function NetReplExportDirEnum;
begin
GetProcedureAddress(_NetReplExportDirEnum, netapi32, 'NetReplExportDirEnum');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirEnum]
end;
end;
{$ELSE}
function NetReplExportDirEnum; external netapi32 name 'NetReplExportDirEnum';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirGetInfo: Pointer;
function NetReplExportDirGetInfo;
begin
GetProcedureAddress(_NetReplExportDirGetInfo, netapi32, 'NetReplExportDirGetInfo');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirGetInfo]
end;
end;
{$ELSE}
function NetReplExportDirGetInfo; external netapi32 name 'NetReplExportDirGetInfo';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirSetInfo: Pointer;
function NetReplExportDirSetInfo;
begin
GetProcedureAddress(_NetReplExportDirSetInfo, netapi32, 'NetReplExportDirSetInfo');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirSetInfo]
end;
end;
{$ELSE}
function NetReplExportDirSetInfo; external netapi32 name 'NetReplExportDirSetInfo';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirLock: Pointer;
function NetReplExportDirLock;
begin
GetProcedureAddress(_NetReplExportDirLock, netapi32, 'NetReplExportDirLock');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirLock]
end;
end;
{$ELSE}
function NetReplExportDirLock; external netapi32 name 'NetReplExportDirLock';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplExportDirUnlock: Pointer;
function NetReplExportDirUnlock;
begin
GetProcedureAddress(_NetReplExportDirUnlock, netapi32, 'NetReplExportDirUnlock');
asm
mov esp, ebp
pop ebp
jmp [_NetReplExportDirUnlock]
end;
end;
{$ELSE}
function NetReplExportDirUnlock; external netapi32 name 'NetReplExportDirUnlock';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirAdd: Pointer;
function NetReplImportDirAdd;
begin
GetProcedureAddress(_NetReplImportDirAdd, netapi32, 'NetReplImportDirAdd');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirAdd]
end;
end;
{$ELSE}
function NetReplImportDirAdd; external netapi32 name 'NetReplImportDirAdd';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirDel: Pointer;
function NetReplImportDirDel;
begin
GetProcedureAddress(_NetReplImportDirDel, netapi32, 'NetReplImportDirDel');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirDel]
end;
end;
{$ELSE}
function NetReplImportDirDel; external netapi32 name 'NetReplImportDirDel';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirEnum: Pointer;
function NetReplImportDirEnum;
begin
GetProcedureAddress(_NetReplImportDirEnum, netapi32, 'NetReplImportDirEnum');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirEnum]
end;
end;
{$ELSE}
function NetReplImportDirEnum; external netapi32 name 'NetReplImportDirEnum';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirGetInfo: Pointer;
function NetReplImportDirGetInfo;
begin
GetProcedureAddress(_NetReplImportDirGetInfo, netapi32, 'NetReplImportDirGetInfo');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirGetInfo]
end;
end;
{$ELSE}
function NetReplImportDirGetInfo; external netapi32 name 'NetReplImportDirGetInfo';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirLock: Pointer;
function NetReplImportDirLock;
begin
GetProcedureAddress(_NetReplImportDirLock, netapi32, 'NetReplImportDirLock');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirLock]
end;
end;
{$ELSE}
function NetReplImportDirLock; external netapi32 name 'NetReplImportDirLock';
{$ENDIF DYNAMIC_LINK}
{$IFDEF DYNAMIC_LINK}
var
_NetReplImportDirUnlock: Pointer;
function NetReplImportDirUnlock;
begin
GetProcedureAddress(_NetReplImportDirUnlock, netapi32, 'NetReplImportDirUnlock');
asm
mov esp, ebp
pop ebp
jmp [_NetReplImportDirUnlock]
end;
end;
{$ELSE}
function NetReplImportDirUnlock; external netapi32 name 'NetReplImportDirUnlock';
{$ENDIF DYNAMIC_LINK}
end.
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -