// AtlSpaceship.h : Declaration of the CAtlSpaceship #ifndef __ATLSPACESHIP_H_ #define __ATLSPACESHIP_H_ #include "resource.h" // main symbols ///////////////////////////////////////////////////////////////////////////// // CAtlSpaceship class ATL_NO_VTABLE CAtlSpaceship : public CComObjectRootEx, public CComCoClass, public IDispatchImpl, public IDispatchImpl, public IDispatchImpl { public: CAtlSpaceship() { m_nPosition = 0; m_nAcceleration = 0; m_nColor = 0; } DECLARE_REGISTRY_RESOURCEID(IDR_ATLSPACESHIP) DECLARE_PROTECT_FINAL_CONSTRUCT() BEGIN_COM_MAP(CAtlSpaceship) COM_INTERFACE_ENTRY(IAtlSpaceship) COM_INTERFACE_ENTRY(IMotion) COM_INTERFACE_ENTRY2(IDispatch, IAtlSpaceship) COM_INTERFACE_ENTRY(IVisual) END_COM_MAP() // IAtlSpaceship public: STDMETHOD(Display)(); STDMETHOD(GetPosition)(long* nPosition); STDMETHOD(Fly)(); STDMETHOD(CallStarFleet)(/*[in]*/float fStarDate, /*[out, retval]*/BSTR* pbstrRecipient); int m_nPosition; int m_nAcceleration; int m_nColor; }; #endif //__ATLSPACESHIP_H_