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.

45 lines
831 B

  1. // File richaddr.h
  2. //
  3. // RichAddress definitions
  4. #ifndef _RICH_ADDR_H_
  5. #define _RICH_ADDR_H_
  6. #include "SDKInternal.h"
  7. typedef struct DWSTR
  8. {
  9. DWORD dw;
  10. LPTSTR psz;
  11. } DWSTR;
  12. typedef struct RichAddressInfo
  13. {
  14. TCHAR szName[ 256 ];
  15. int cItems;
  16. DWSTR rgDwStr[ 1 ];
  17. } RichAddressInfo, RAI;
  18. interface IEnumRichAddressInfo
  19. {
  20. public:
  21. virtual ULONG STDMETHODCALLTYPE AddRef(void) = 0;
  22. virtual ULONG STDMETHODCALLTYPE Release(void) = 0;
  23. virtual HRESULT STDMETHODCALLTYPE GetAddress(
  24. long index,
  25. RichAddressInfo **ppAddr) = 0;
  26. };
  27. inline
  28. bool
  29. hasValidUserInfo
  30. (
  31. const RichAddressInfo * const rai
  32. ){
  33. return( (rai != NULL) && (rai->cItems > 0) && (rai->rgDwStr[ 0 ].psz != NULL) && (rai->rgDwStr[ 0 ].psz[ 0 ] != '\0') );
  34. }
  35. #endif /* _RICH_ADDR_H_ */