📄 pservice.h
字号:
//
// Copyright (c) Microsoft Corporation. All rights reserved.
//
//
// Use of this source code is subject to the terms of the Microsoft end-user
// license agreement (EULA) under which you licensed this SOFTWARE PRODUCT.
// If you did not accept the terms of the EULA, you are not authorized to use
// this source code. For a copy of the EULA, please see the LICENSE.RTF on your
// install media.
//
/*++
THIS CODE AND INFORMATION IS PROVIDED "AS IS" WITHOUT WARRANTY OF
ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING BUT NOT LIMITED TO
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND/OR FITNESS FOR A
PARTICULAR PURPOSE.
Module Name:
pservice.h
Abstract:
Private portion of service.h
Notes:
--*/
#if ! defined (__pservice_H__)
#define __pservice_H__ 1
#ifdef __cplusplus
extern "C" {
#endif
HANDLE ActivateService(LPCWSTR lpszDevKey, DWORD dwClientInfo);
HANDLE RegisterService(LPCWSTR lpszType, DWORD dwIndex, LPCWSTR lpszLib, DWORD dwInfo);
BOOL DeregisterService(HANDLE hDevice);
void CloseAllServiceHandles(HANDLE proc);
HANDLE CreateServiceHandle(LPCWSTR lpNew, DWORD dwAccess, DWORD dwShareMode, HANDLE hProc);
BOOL GetServiceByIndex(DWORD dwIndex, LPWIN32_FIND_DATA lpFindFileData);
BOOL ServiceIoControl(HANDLE hService, DWORD dwIoControlCode, LPVOID lpInBuf, DWORD nInBufSize, LPVOID lpOutBuf, DWORD nOutBufSize,
LPDWORD lpBytesReturned, LPOVERLAPPED lpOverlapped);
#if defined (_WINSOCKAPI_) || defined (_WINSOCK2API_)
BOOL ServiceAddPort(HANDLE hService, SOCKADDR *pSockAddr, int cbSockAddr, int iProtocol, WCHAR *szRegWritePath);
BOOL ServiceClosePort(HANDLE hService, SOCKADDR *pSockAddr, int cbSockAddr, int iProtocol, BOOL fRemoveFromRegistry);
#endif
BOOL ServiceUnbindPorts(HANDLE hService);
BOOL EnumServices(PBYTE pBuffer, DWORD *pdwServiceEntries, DWORD *pdwBufferLen);
HANDLE GetServiceHandle(LPWSTR szPrefix, LPWSTR szDllName, DWORD *pdwDllBuf);
#ifdef __cplusplus
}
#endif
#endif /* __pservice_H__ */
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -