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.

84 lines
2.6 KiB

  1. // PCHSEResultItem.cpp : Implementation of SearchEngine::ResultItem
  2. #include "stdafx.h"
  3. SearchEngine::ResultItem_Data::ResultItem_Data()
  4. {
  5. // CComBSTR m_bstrTitle;
  6. // CComBSTR m_bstrURI;
  7. m_lContentType = 0; // long m_lContentType;
  8. // CComBSTR m_bstrLocation;
  9. m_lHits = 0; // long m_lHits;
  10. m_dRank = 0; // double m_dRank;
  11. // CComBSTR m_bstrImageURL;
  12. // CComBSTR m_bstrVendor;
  13. // CComBSTR m_bstrProduct;
  14. // CComBSTR m_bstrComponent;
  15. // CComBSTR m_bstrDescription;
  16. m_dateLastModified = 0; // DATE m_dateLastModified;
  17. }
  18. /////////////////////////////////////////////////////////////////////////////
  19. // SearchEngine::ResultItem
  20. SearchEngine::ResultItem::ResultItem()
  21. {
  22. // ResultItem_Data m_data;
  23. }
  24. STDMETHODIMP SearchEngine::ResultItem::get_Title( BSTR *pVal )
  25. {
  26. __HCP_BEGIN_PROPERTY_GET("SearchEngine::ResultItem::get_Title",hr,pVal);
  27. __MPC_EXIT_IF_METHOD_FAILS(hr, MPC::GetBSTR( m_data.m_bstrTitle, pVal ));
  28. __HCP_END_PROPERTY(hr);
  29. }
  30. STDMETHODIMP SearchEngine::ResultItem::get_URI( BSTR *pVal )
  31. {
  32. __HCP_BEGIN_PROPERTY_GET("SearchEngine::ResultItem::get_URI",hr,pVal);
  33. __MPC_EXIT_IF_METHOD_FAILS(hr, MPC::GetBSTR( m_data.m_bstrURI, pVal ));
  34. __HCP_END_PROPERTY(hr);
  35. }
  36. STDMETHODIMP SearchEngine::ResultItem::get_ContentType( long *pVal )
  37. {
  38. __HCP_BEGIN_PROPERTY_GET2("SearchEngine::ResultItem::get_ContentType",hr,pVal,m_data.m_lContentType);
  39. __HCP_END_PROPERTY(hr);
  40. }
  41. STDMETHODIMP SearchEngine::ResultItem::get_Location( BSTR *pVal )
  42. {
  43. __HCP_BEGIN_PROPERTY_GET("SearchEngine::ResultItem::get_Location",hr,pVal);
  44. __MPC_EXIT_IF_METHOD_FAILS(hr, MPC::GetBSTR( m_data.m_bstrLocation, pVal ));
  45. __HCP_END_PROPERTY(hr);
  46. }
  47. STDMETHODIMP SearchEngine::ResultItem::get_Hits( long *pVal )
  48. {
  49. __HCP_BEGIN_PROPERTY_GET2("SearchEngine::ResultItem::get_Hits",hr,pVal,m_data.m_lHits);
  50. __HCP_END_PROPERTY(hr);
  51. }
  52. STDMETHODIMP SearchEngine::ResultItem::get_Rank( double *pVal )
  53. {
  54. __HCP_BEGIN_PROPERTY_GET2("SearchEngine::ResultItem::get_Rank",hr,pVal,m_data.m_dRank);
  55. __HCP_END_PROPERTY(hr);
  56. }
  57. STDMETHODIMP SearchEngine::ResultItem::get_Description( BSTR *pVal )
  58. {
  59. __HCP_BEGIN_PROPERTY_GET("SearchEngine::ResultItem::get_Description",hr,pVal);
  60. __MPC_EXIT_IF_METHOD_FAILS(hr, MPC::GetBSTR( m_data.m_bstrDescription, pVal ));
  61. __HCP_END_PROPERTY(hr);
  62. }