IAGCStationImpl.h 1.5 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. #ifndef __IAGCStationImpl_h__
  2. #define __IAGCStationImpl_h__
  3. /////////////////////////////////////////////////////////////////////////////
  4. // IAGCStationImpl.h : Declaration of the IAGCStationImpl class template.
  5. //
  6. #include "IAGCScannerImpl.h"
  7. /////////////////////////////////////////////////////////////////////////////
  8. // Interface Map Macro
  9. //
  10. // Classes derived from IAGCStationImpl should include this macro in their
  11. // interface maps.
  12. //
  13. #define COM_INTERFACE_ENTRIES_IAGCStationImpl() \
  14. COM_INTERFACE_ENTRY(IAGCStation) \
  15. COM_INTERFACE_ENTRY(IDispatch) \
  16. COM_INTERFACE_ENTRIES_IAGCScannerImpl()
  17. /////////////////////////////////////////////////////////////////////////////
  18. // IAGCStationImpl
  19. //
  20. template <class T, class IGC, class ITF, const GUID* plibid>
  21. class ATL_NO_VTABLE IAGCStationImpl :
  22. public IAGCScannerImpl<T, IGC, ITF, plibid, IstationIGC, IAGCStation>
  23. {
  24. // Types
  25. public:
  26. typedef IAGCStationImpl<T, IGC, ITF, plibid> IAGCStationImplBase;
  27. // IAGCStation Interface Methods
  28. public:
  29. STDMETHODIMP put_ShieldFraction(float Val)
  30. {
  31. assert(GetIGC());
  32. GetIGC()->SetShieldFraction(Val);
  33. return S_OK;
  34. }
  35. STDMETHODIMP get_ShieldFraction(float* pVal)
  36. {
  37. assert(GetIGC());
  38. CLEAROUT(pVal, GetIGC()->GetShieldFraction());
  39. return S_OK;
  40. }
  41. };
  42. /////////////////////////////////////////////////////////////////////////////
  43. #endif //__IAGCStationImpl_h__