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.

182 lines
6.6 KiB

  1. //****************************************************************************
  2. //
  3. // Module: ULS.DLL
  4. // File: ulsmeet.h
  5. // Content: This file contains the MeetingPlace object definition.
  6. // History:
  7. // Mon 11-Nov-96 -by- Shishir Pardikar [shishirp]
  8. //
  9. // Copyright (c) Microsoft Corporation 1996-1997
  10. //
  11. //****************************************************************************
  12. #ifndef _ULSMEET_H_
  13. #define _ULSMEET_H_
  14. #ifdef ENABLE_MEETING_PLACE
  15. #include "connpt.h"
  16. #include "attribs.h"
  17. #include "culs.h"
  18. class CIlsMeetingPlace: public IIlsMeetingPlace,
  19. public IConnectionPointContainer
  20. {
  21. #define UNDEFINED_TYPE -1
  22. #define ILS_MEET_FLAG_REGISTERED 0x00000001
  23. #define ILS_MEET_MODIFIED_MASK 0xffff0000
  24. #define ILS_MEET_FLAG_HOST_NAME_MODIFIED 0x00010000
  25. #define ILS_MEET_FLAG_HOST_ADDRESS_MODIFIED 0x00020000
  26. #define ILS_MEET_FLAG_DESCRIPTION_MODIFIED 0x00040000
  27. #define ILS_MEET_FLAG_EXTENDED_ATTRIBUTES_MODIFIED 0x00080000
  28. #define ILS_MEET_ALL_MODIFIED ILS_MEET_MODIFIED_MASK
  29. private:
  30. LONG m_cRef; // ref count on this object
  31. // members to keep track of properties
  32. ULONG m_ulState; // the current state of this object
  33. // as defined by ULSState enum type
  34. LPTSTR m_pszMeetingPlaceID; // globally unique ID for the MeetingPlace
  35. LONG m_lMeetingPlaceType; // meetingtype, eg: netmeeting, doom etc.
  36. LONG m_lAttendeeType; // type of Attendees, eg: urls, rtperson DNs etc.
  37. LPTSTR m_pszHostName; // Host who registered this MeetingPlace
  38. LPTSTR m_pszHostIPAddress; // IP address of the host
  39. LPTSTR m_pszDescription; // description eg: discussing ski trip
  40. CAttributes m_ExtendedAttrs; // User defined attributes
  41. HANDLE m_hMeetingPlace; // handle from ulsldap_register
  42. CConnectionPoint *m_pConnectionPoint;
  43. // bookkeeping
  44. DWORD m_dwFlags; // Always a good idea
  45. // server object
  46. CIlsServer *m_pIlsServer;
  47. STDMETHODIMP AllocMeetInfo(PLDAP_MEETINFO *ppMeetInfo, ULONG ulMask);
  48. public:
  49. // Constructor
  50. CIlsMeetingPlace();
  51. // destructor
  52. ~CIlsMeetingPlace(VOID);
  53. STDMETHODIMP Init(BSTR bstrMeetingPlaceID, LONG lMeetingPlaceType, LONG lAttendeeType);
  54. STDMETHODIMP Init(CIlsServer *pIlsServer, PLDAP_MEETINFO pMeetInfo);
  55. STDMETHODIMP NotifySink(VOID *pv, CONN_NOTIFYPROC pfn);
  56. STDMETHODIMP RegisterResult(ULONG ulRegID, HRESULT hr);
  57. STDMETHODIMP UnregisterResult(ULONG ulRegID, HRESULT hr);
  58. STDMETHODIMP UpdateResult(ULONG ulUpdateID, HRESULT hr);
  59. STDMETHODIMP AddAttendeeResult(ULONG ulID, HRESULT hr);
  60. STDMETHODIMP RemoveAttendeeResult(ULONG ulID, HRESULT hr);
  61. STDMETHODIMP EnumAttendeeNamesResult(ULONG ulEnumAttendees, PLDAP_ENUM ple);
  62. // IUnknown members
  63. STDMETHODIMP QueryInterface (REFIID iid, void **ppv);
  64. STDMETHODIMP_(ULONG) AddRef (void);
  65. STDMETHODIMP_(ULONG) Release (void);
  66. // IIlsMeetingPlace Interface members
  67. // Interfaces related to attributes
  68. // all these operate locally on the object and generate
  69. // no net traffic.
  70. // Get the type of meeting and Attendee
  71. // these are not changeable once the
  72. // meeting is registered
  73. STDMETHODIMP GetState(ULONG *ulState);
  74. STDMETHODIMP GetMeetingPlaceType(LONG *plMeetingPlaceType);
  75. STDMETHODIMP GetAttendeeType(LONG *plAttendeeType);
  76. STDMETHODIMP GetStandardAttribute(
  77. ILS_STD_ATTR_NAME stdAttr,
  78. BSTR *pbstrStdAttr);
  79. STDMETHODIMP SetStandardAttribute(
  80. ILS_STD_ATTR_NAME stdAttr,
  81. BSTR pbstrStdAttr);
  82. STDMETHODIMP GetExtendedAttribute ( BSTR bstrName, BSTR *pbstrValue );
  83. STDMETHODIMP SetExtendedAttribute ( BSTR bstrName, BSTR bstrValue );
  84. STDMETHODIMP RemoveExtendedAttribute ( BSTR bstrName );
  85. STDMETHODIMP GetAllExtendedAttributes ( IIlsAttributes **ppAttributes );
  86. // Registers a meeting with the server
  87. STDMETHODIMP Register ( IIlsServer *pServer, ULONG *pulRegID );
  88. // The following 5 interfaces work only on an object that has been
  89. // a) used to register a meeting
  90. // or b) obtained from IIls::EnumMeetingPlaces
  91. STDMETHODIMP Unregister(ULONG *pulUnregID);
  92. STDMETHODIMP Update(ULONG *pulUpdateID);
  93. STDMETHODIMP AddAttendee(BSTR bstrAttendeeID, ULONG *pulAddAttendeeID);
  94. STDMETHODIMP RemoveAttendee(BSTR bstrAttendeeID, ULONG *pulRemoveAttendeeID);
  95. STDMETHODIMP EnumAttendeeNames(IIlsFilter *pFilter, ULONG *pulEnumAttendees);
  96. // Connection point container. It has only one
  97. // connection interface, and that is to notify
  98. // IConnectionPointContainer
  99. STDMETHODIMP EnumConnectionPoints(IEnumConnectionPoints **ppEnum);
  100. STDMETHODIMP FindConnectionPoint(REFIID riid,
  101. IConnectionPoint **ppcp);
  102. };
  103. //****************************************************************************
  104. // CEnumMeetingPlaces definition
  105. //****************************************************************************
  106. //
  107. class CEnumMeetingPlaces : public IEnumIlsMeetingPlaces
  108. {
  109. private:
  110. LONG m_cRef;
  111. CIlsMeetingPlace **m_ppMeetingPlaces;
  112. ULONG m_cMeetingPlaces;
  113. ULONG m_iNext;
  114. public:
  115. // Constructor and Initialization
  116. CEnumMeetingPlaces (void);
  117. ~CEnumMeetingPlaces (void);
  118. STDMETHODIMP Init (CIlsMeetingPlace **ppMeetingPlacesList, ULONG cMeetingPlaces);
  119. // IUnknown
  120. STDMETHODIMP QueryInterface (REFIID iid, void **ppv);
  121. STDMETHODIMP_(ULONG) AddRef (void);
  122. STDMETHODIMP_(ULONG) Release (void);
  123. // IEnumIlsMeetingPlaces
  124. STDMETHODIMP Next(ULONG cMeetingPlaces, IIlsMeetingPlace **rgpMeetingPlaces,
  125. ULONG *pcFetched);
  126. STDMETHODIMP Skip(ULONG cMeetingPlaces);
  127. STDMETHODIMP Reset();
  128. STDMETHODIMP Clone(IEnumIlsMeetingPlaces **ppEnum);
  129. };
  130. #endif // ENABLE_MEETING_PLACE
  131. #endif //