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.

113 lines
2.5 KiB

  1. /*
  2. - PROPS.CPP
  3. -
  4. * Microsoft NetMeeting
  5. * Quality of Service DLL
  6. * IProp interfaces
  7. *
  8. * Revision History:
  9. *
  10. * When Who What
  11. * -------- ------------------ ---------------------------------------
  12. * 11.06.96 Yoram Yaacovi Created
  13. *
  14. * Functions:
  15. * IProp
  16. * CQoS::GetProps
  17. * CQoS::SetProps
  18. */
  19. #include "precomp.h"
  20. /***************************************************************************
  21. Name : CQoS::SetProps
  22. Purpose : Set properties on the QoS object
  23. Parameters: cValues - number of properties to set
  24. pPropArray - pointer to the array of the properties to set
  25. Returns : HRESULT
  26. Comment :
  27. ***************************************************************************/
  28. HRESULT CQoS::SetProps (ULONG cValues,
  29. PPROPERTY pPropArray)
  30. {
  31. HRESULT hr=NOERROR;
  32. ULONG i;
  33. DEBUGMSG(ZONE_IQOS,("IQoS::SetProps\n"));
  34. /*
  35. * Parameter validation
  36. */
  37. if (!pPropArray)
  38. {
  39. hr = ResultFromScode(E_INVALIDARG);
  40. goto out;
  41. }
  42. /*
  43. * Set the properties
  44. */
  45. // for every property to set...
  46. for (i=0; i < cValues; i++)
  47. {
  48. // just handle the props I know of
  49. switch (pPropArray[i].ulPropTag)
  50. {
  51. case PR_QOS_WINDOW_HANDLE:
  52. m_hWnd = (HWND) pPropArray[i].Value.ul;
  53. pPropArray[i].hResult = NOERROR;
  54. break;
  55. default:
  56. pPropArray[i].hResult = QOS_E_NO_SUCH_PROPERTY;
  57. hr = QOS_E_REQ_ERRORS;
  58. break;
  59. }
  60. }
  61. out:
  62. DEBUGMSG(ZONE_IQOS,("IQoS::SetProps - leave, hr=0x%x\n", hr));
  63. return hr;
  64. }
  65. /***************************************************************************
  66. Name : CQoS::GetProps
  67. Purpose : Get properties from the QoS object
  68. Parameters: pPropTagArray - array of tags of properties to get
  69. ulFlags
  70. pcValues - address of a ULONG into which the function will
  71. put the number of the properties returned in *ppPropArray
  72. ppPropArray - address of a pointer where the function will
  73. put the address of the returned properties buffer. The
  74. caller must free this buffer when done.
  75. Returns : HRESULT
  76. Comment : Not implemented
  77. ***************************************************************************/
  78. HRESULT CQoS::GetProps (PPROPTAGARRAY pPropTagArray,
  79. ULONG ulFlags,
  80. ULONG *pcValues,
  81. PPROPERTY *ppPropArray)
  82. {
  83. HRESULT hr=NOERROR;
  84. DEBUGMSG(ZONE_IQOS,("IQoS::GetProps\n"));
  85. hr = E_NOTIMPL;
  86. goto out;
  87. out:
  88. DEBUGMSG(ZONE_IQOS,("QoS::GetProps - leave, hr=0x%x\n", hr));
  89. return hr;
  90. }