Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

54 lines
1.6 KiB

  1. // AppleTalk.h : Declaration of the CAppleTalk
  2. #ifndef __APPLETALK_H_
  3. #define __APPLETALK_H_
  4. #include "resource.h" // main symbols
  5. #include <string>
  6. #include <vector>
  7. #include "AtlkAdapter.h"
  8. using namespace std;
  9. /////////////////////////////////////////////////////////////////////////////
  10. // CAppleTalk
  11. class ATL_NO_VTABLE CAppleTalk :
  12. public CComObjectRootEx<CComSingleThreadModel>,
  13. public CComCoClass<CAppleTalk, &CLSID_AppleTalk>,
  14. public ISupportErrorInfo,
  15. public IDispatchImpl<IAppleTalk, &IID_IAppleTalk, &LIBID_SAAPPLETALKLib>
  16. {
  17. public:
  18. CAppleTalk()
  19. {
  20. }
  21. DECLARE_REGISTRY_RESOURCEID(IDR_APPLETALK)
  22. DECLARE_PROTECT_FINAL_CONSTRUCT()
  23. BEGIN_COM_MAP(CAppleTalk)
  24. COM_INTERFACE_ENTRY(IAppleTalk)
  25. COM_INTERFACE_ENTRY(IDispatch)
  26. COM_INTERFACE_ENTRY(ISupportErrorInfo)
  27. END_COM_MAP()
  28. // ISupportsErrorInfo
  29. STDMETHOD(InterfaceSupportsErrorInfo)(REFIID riid);
  30. // IAppleTalk
  31. public:
  32. STDMETHOD(SetAsDefaultPort)(/*[in]*/ BSTR bstrDeviceName);
  33. STDMETHOD(IsDefaultPort)(/*[in]*/ BSTR bstrDeviceName, /*[out,retval]*/ BOOL * bDefaultPort);
  34. STDMETHOD(get_Zone)(/*[in]*/ BSTR bstrDeviceName, /*[out, retval]*/ BSTR *pVal);
  35. STDMETHOD(put_Zone)(/*[in]*/ BSTR bstrDeviceName, /*[in]*/ BSTR newVal);
  36. STDMETHOD(GetZones)(/*[in]*/ BSTR bstrDeviceName, /*[out,retval]*/ VARIANT* pbstrZones);
  37. private:
  38. //bool GetZonesForAdapter(const WCHAR* pwcDeviceName, vector<wstring>& rZones);
  39. HRESULT GetZonesForAdapter(const WCHAR* pwcDeviceName, TZoneListVector *prZones);
  40. wstring m_wsCurrentZone;
  41. };
  42. #endif //__APPLETALK_H_