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.

53 lines
1.7 KiB

  1. //*****************************************************************************
  2. //
  3. // Microsoft Windows Media
  4. // Copyright (C) Microsoft Corporation. All rights reserved.
  5. //
  6. // FileName: colldispid.h
  7. //
  8. // Abstract:
  9. //
  10. //*****************************************************************************
  11. #pragma once
  12. #ifndef __COLLDISPID_H_
  13. #define __COLLDISPID_H_
  14. #ifndef DISPID_LISTITEM
  15. #define DISPID_LISTITEM 0
  16. #endif
  17. //
  18. // Standard collection count defined in olectl.h.
  19. //
  20. #ifndef DISPID_LISTCOUNT
  21. #define DISPID_LISTCOUNT (-531)
  22. #endif
  23. //
  24. // Create a non standard one for length which is the Java equivalent to Count
  25. //
  26. #ifndef DISPID_COLLCOUNT
  27. #define DISPID_COLLCOUNT (-530)
  28. #endif
  29. #ifndef DISPID_NEWENUM
  30. #define DISPID_NEWENUM (-4)
  31. #endif
  32. //
  33. // A macro to create the standard collection Methods & Properties: Item, Count, length & _NewEnum
  34. // Count and length return the same thing but one is geared towards VB/Automation
  35. // collections (COUNT) and the other towards Java/JScript (length).
  36. #define COLLECTION_METHODS( type, strHelp ) \
  37. [propget, id(DISPID_LISTITEM), helpstring( strHelp )] HRESULT \
  38. Item([in] const VARIANT varIndex, [out, retval] type *pVal); \
  39. [propget, id(DISPID_LISTCOUNT), helpstring("Retrieves the number of items in the collection.")] HRESULT \
  40. Count([out, retval] long *pVal); \
  41. [propget, id(DISPID_COLLCOUNT), helpstring("Retrieves the number of items in the collection.")] HRESULT \
  42. length([out, retval] long *pVal); \
  43. [propget, id(DISPID_NEWENUM), restricted, hidden] HRESULT \
  44. _NewEnum([out, retval] IUnknown* *pVal);
  45. #endif