GME  13
ComponentProxy.h
Go to the documentation of this file.
00001 // ComponentProxy.h : Declaration of the CComponentProxy
00002 
00003 #ifndef __COMPONENTPROXY_H_
00004 #define __COMPONENTPROXY_H_
00005 
00006 #include "resource.h"       // main symbols
00007 
00009 // CComponentProxy
00010 class ATL_NO_VTABLE CComponentProxy : 
00011         public CComObjectRootEx<CComSingleThreadModel>,
00012         public CComCoClass<CComponentProxy, &__uuidof(ComponentProxy)>,
00013         public IMgaComponentProxy,
00014         public IMgaComponentEx,
00015         public IGMEVersionInfo
00016 {
00017 public:
00018         CComponentProxy()
00019         {
00020         }
00021 
00022 DECLARE_REGISTRY_RESOURCEID(IDR_COMPONENTPROXY)
00023 
00024 DECLARE_PROTECT_FINAL_CONSTRUCT()
00025 
00026 BEGIN_COM_MAP(CComponentProxy)
00027         COM_INTERFACE_ENTRY(IMgaComponentProxy)
00028         COM_INTERFACE_ENTRY(IMgaComponent)
00029         COM_INTERFACE_ENTRY(IMgaComponentEx)
00030         COM_INTERFACE_ENTRY(IGMEVersionInfo)
00031 END_COM_MAP()
00032 
00033 
00034 public:
00035 
00036         // IMgaComponentProxy
00037         STDMETHOD(put_DispatchComponent)(/*[in]*/ IDispatch *component);
00038         
00039         // IMgaComponent
00040         STDMETHOD(Invoke)(/*[in]*/ IMgaProject *project, /*[in]*/ IMgaFCOs *selectedobjs, /*[in]*/ long param);
00041         STDMETHOD(Initialize)(IMgaProject *p);
00042         STDMETHOD(Enable)(VARIANT_BOOL newVal);
00043         STDMETHOD(get_InteractiveMode)(/*[out, retval]*/ VARIANT_BOOL * enabled);
00044         STDMETHOD(put_InteractiveMode)(/*[in]*/ VARIANT_BOOL enabled);
00045         STDMETHOD(get_ComponentName)(/*[out, retval]*/ BSTR *pVal);
00046         STDMETHOD(get_ComponentType)(/*[out, retval]*/ componenttype_enum *t);
00047         STDMETHOD(get_Paradigm)(/*[out, retval]*/ BSTR *pVal);
00048         
00049         // IMgaComponentEx
00050         STDMETHOD(InvokeEx)(/*[in]*/ IMgaProject *project, /*[in]*/ IMgaFCO *currentobj, /*[in,out]*/ IMgaFCOs *selectedobjs, /*[in]*/ long param);
00051         STDMETHOD(ObjectsInvokeEx)(/*[in]*/ IMgaProject *project, /*[in]*/ IMgaObject *currentobj, /*[in,out]*/ IMgaObjects *selectedobjs, /*[in]*/ long param);
00052         STDMETHOD(get_ComponentProgID)(/*[out, retval]*/ BSTR *pVal);
00053         STDMETHOD(put_ComponentParameter)(/*[in]*/ BSTR name, /*[in]*/ VARIANT newVal);
00054         STDMETHOD(get_ComponentParameter)(/*[in]*/ BSTR name, /*[out, retval]*/ VARIANT *pVal);
00055         
00056         // IGMEVersionInfo
00057         STDMETHOD(get_version)(/*[out, retval]*/ GMEInterfaceVersion_enum *pVal);
00058 
00059 protected:
00060         CComDispatchDriver m_dispatch;
00061 };
00062 
00063 #endif //__COMPONENTPROXY_H_