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.

82 lines
2.0 KiB

  1. /********************************************************************
  2. Copyright (c) 1999 Microsoft Corporation
  3. Module Name:
  4. User.cpp
  5. Abstract:
  6. SAFUser Object
  7. Revision History:
  8. KalyaninN created 09/29/'00
  9. ********************************************************************/
  10. // User.cpp : Implementation of CSAFUser
  11. #include "stdafx.h"
  12. /////////////////////////////////////////////////////////////////////////////
  13. // CSAFUser
  14. #include <HCP_trace.h>
  15. /////////////////////////////////////////////////////////////////////////////
  16. // construction / destruction
  17. // **************************************************************************
  18. CSAFUser::CSAFUser()
  19. {
  20. }
  21. // **************************************************************************
  22. CSAFUser::~CSAFUser()
  23. {
  24. Cleanup();
  25. }
  26. // **************************************************************************
  27. void CSAFUser::Cleanup(void)
  28. {
  29. }
  30. /////////////////////////////////////////////////////////////////////////////
  31. // CSAFUser Properties
  32. STDMETHODIMP CSAFUser::get_UserName(BSTR *pbstrUserName)
  33. {
  34. MPC::SmartLock<_ThreadModel> lock( this );
  35. return MPC::GetBSTR( m_bstrUserName, pbstrUserName );
  36. }
  37. // **************************************************************************
  38. STDMETHODIMP CSAFUser::get_DomainName(BSTR *pbstrDomainName)
  39. {
  40. MPC::SmartLock<_ThreadModel> lock( this );
  41. return MPC::GetBSTR( m_bstrDomainName, pbstrDomainName );
  42. }
  43. // **************************************************************************
  44. STDMETHODIMP CSAFUser::put_UserName(BSTR bstrUserName)
  45. {
  46. MPC::SmartLock<_ThreadModel> lock( this );
  47. return MPC::PutBSTR( m_bstrUserName, bstrUserName );
  48. }
  49. // **************************************************************************
  50. STDMETHODIMP CSAFUser::put_DomainName(BSTR bstrDomainName)
  51. {
  52. MPC::SmartLock<_ThreadModel> lock( this );
  53. return MPC::PutBSTR( m_bstrDomainName, bstrDomainName );
  54. }