📄 hxcomm.h
字号:
/************************************************************************ * IHXServerControl2::RestartServer * * Purpose: * * Completely shutdown the server, then restart. Mainly used to * cause not hot setting config var changes to take effect. */ STDMETHOD(RestartServer) (THIS) PURE; /************************************************************************ * IHXServerControl2::ReconfigServer * * Purpose: * * Used to cause the server to re-read in config from file or registry * (however it was started) and attempt to use the values. */ STDMETHOD(ReconfigServer) (THIS_ IHXReconfigServerResponse* pResp) PURE;};/* * * Interface: * * IHXReconfigServerResponse * * Purpose: * * Response interface for IHXServerControl2::ReconfigServer * * * IID_IHXReconfigServerResponse: * * {00000006-0901-11d1-8B06-00A024406D59} * */DEFINE_GUID(IID_IHXReconfigServerResponse, 0x00000006, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXReconfigServerResponseDECLARE_INTERFACE_(IHXReconfigServerResponse, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; /************************************************************************ * IHXReconfigServerResponse::ReconfigServerDone * * Purpose: * * Notification that reconfiguring the server is done. */ STDMETHOD(ReconfigServerDone) (THIS_ HX_RESULT res, IHXBuffer** pInfo, UINT32 ulNumInfo) PURE;};/* * * Interface: * * IHXServerReconfigNotification * * Purpose: * * Register with the server that you want notification when a reconfig * request comes in and want/need to take part in the reconfiguration. This * is used when you have configuration info outside the server config file * which needs to be re-initialized. * * * IID_IHXServerReconfigNotification: * * {00000007-0901-11d1-8B06-00A024406D59} * */DEFINE_GUID(IID_IHXServerReconfigNotification, 0x00000007, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXServerReconfigNotificationDECLARE_INTERFACE_(IHXServerReconfigNotification, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; /************************************************************************ * IHXServerReconfigNotification::WantReconfigNotification * * Purpose: * * Tell the server that you want reconfig notification. */ STDMETHOD(WantReconfigNotification) (THIS_ IHXWantServerReconfigNotification* pResponse) PURE; /************************************************************************ * IHXServerReconfigNotification::CancelReconfigNotification * * Purpose: * * Tell the server that you no longer want reconfig notification. */ STDMETHOD(CancelReconfigNotification) (THIS_ IHXWantServerReconfigNotification* pResponse) PURE;};/* * * Interface: * * IHXWantServerReconfigNotification * * Purpose: * * Tell user that the server got a reconfig request and it is time to * do your reconfiguration. NOTE: You should not need this if all of your * configuration is stored in the config file; that is taken care of through * IHXActiveRegistry. * * IID_IHXWantServerReconfigNotification: * * {00000008-0901-11d1-8B06-00A024406D59} * */DEFINE_GUID(IID_IHXWantServerReconfigNotification, 0x00000008, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXWantServerReconfigNotificationDECLARE_INTERFACE_(IHXWantServerReconfigNotification, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; /************************************************************************ * IHXWantServerReconfigNotification::ServerReconfig * * Purpose: * * Notify user that a server reconfig request had come in and it * is now your turn to do external (not server config) reconfiguration.* */ STDMETHOD(ServerReconfig) (THIS_ IHXReconfigServerResponse* pResponse) PURE;};// $Private:DEFINE_GUID(IID_IHXResolverExec, 0x00000009, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXResolverExecDECLARE_INTERFACE_(IHXResolverExec, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; STDMETHOD(ResolverExec) (THIS_ int readfd, int writefd) PURE;};/**************************************************************************** * * Interface: * * IHXFastAlloc * * Purpose: * * Basic memory management interface. * * IID_IHXFastAlloc: * * {0000000a-0901-11d1-8B06-00A024406D59} * */DEFINE_GUID(IID_IHXFastAlloc, 0x0000000a, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXFastAllocDECLARE_INTERFACE_(IHXFastAlloc, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; /* * IHXFastAlloc methods */ STDMETHOD_(void*,FastAlloc) (THIS_ UINT32 /*IN*/ count) PURE; STDMETHOD_(void,FastFree) (THIS_ void* /*IN*/ pMem) PURE;};#define FAST_CACHE_MEM\ void* operator new(size_t size, IHXFastAlloc* pMalloc = NULL)\ {\ void* pMem;\ if (pMalloc)\ {\ pMem = pMalloc->FastAlloc(size + sizeof(IHXFastAlloc*));\ }\ else\ {\ pMem = (void *)::new char [size + sizeof(IHXFastAlloc*)];\ }\ *(IHXFastAlloc**)pMem = pMalloc;\ return ((unsigned char*)pMem + sizeof(IHXFastAlloc*));\ }\\ void operator delete(void* pMem)\ {\ pMem = (unsigned char*)pMem - sizeof(IHXFastAlloc*);\ IHXFastAlloc* pMalloc = *(IHXFastAlloc**)pMem;\ if (pMalloc)\ {\ pMalloc->FastFree((char *)pMem);\ }\ else\ {\ delete[] (char *)pMem;\ }\ }\/**************************************************************************** * * Interface: * * IHXAccurateClock * * Purpose: * * High Accuracy, Cheap (no system-call) gettimeofday() * [ Only available on some Unix platforms, except QI can fail!! ] * * IID_IHXAccurateClock: * * {0000000b-0901-11d1-8B06-00A024406D59} * */DEFINE_GUID(IID_IHXAccurateClock, 0x0000000b, 0x901, 0x11d1, 0x8b, 0x6, 0x0, 0xa0, 0x24, 0x40, 0x6d, 0x59);#undef INTERFACE#define INTERFACE IHXAccurateClockDECLARE_INTERFACE_(IHXAccurateClock, IUnknown){ /* * IUnknown methods */ STDMETHOD(QueryInterface) (THIS_ REFIID riid, void** ppvObj) PURE; STDMETHOD_(ULONG32,AddRef) (THIS) PURE; STDMETHOD_(ULONG32,Release) (THIS) PURE; /* * IHXAccurateClock methods */ STDMETHOD_(HXTimeval,GetTimeOfDay) (THIS) PURE;};// $EndPrivate.#endif /*_HXCOMM_H_*/
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -