#ifndef _TEST_INPROCSERVERDEMO_HPP_ #define _TEST_INPROCSERVERDEMO_HPP_ #ifndef _COMMON_CONSOLE_HPP_ #include #endif #ifndef _COM_COM_HPP_ #include #endif #ifndef _COM_INSTANTIATOR_HPP_ #include #endif #ifndef _TEST_DEMO_HPP_ #include #endif class InProcServerDemoInstantiator : public Instantiator { public: virtual void *instantiate(IUnknown *pUnkOuter,REFIID riid,void **ppv); }; class InProcServerDemo : public IDemo { public: InProcServerDemo(IUnknown *pUnkOuter,REFIID riid); ~InProcServerDemo(); HRESULT __stdcall QueryInterface(REFIID riid,void **ppv); ULONG __stdcall AddRef(void); ULONG __stdcall Release(void); HRESULT __stdcall getValue(int *pvalue); HRESULT __stdcall setValue(int value); private: int mValue; int mRefCount; }; #endif