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.

77 lines
1.8 KiB

  1. //+---------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. // Copyright (C) Microsoft Corporation, 1992 - 1994.
  5. //
  6. // File: ilangres.hxx
  7. //
  8. // Contents: CLanguageResourceInterface - exposes ICiCLangRes
  9. //
  10. // Classes: CLanguageResourceInterface
  11. //
  12. // History: 2-14-97 mohamedn created
  13. //
  14. //----------------------------------------------------------------------------
  15. #pragma once
  16. #include <ciintf.h>
  17. #include <langres.hxx>
  18. //+---------------------------------------------------------------------------
  19. //
  20. // Class: CLanguageResourceInterface
  21. //
  22. // Purpose: a COM object that exposes ICiCLangRes interface
  23. //
  24. //
  25. // History: 2-14-97 mohamedn created
  26. //
  27. // Notes:
  28. //
  29. //----------------------------------------------------------------------------
  30. class CLanguageResourceInterface : public ICiCLangRes
  31. {
  32. public:
  33. CLanguageResourceInterface() : _refCount(1)
  34. {
  35. // constructor
  36. }
  37. //
  38. // IUnknown methods.
  39. //
  40. STDMETHOD(QueryInterface) (THIS_ REFIID riid,LPVOID *ppiuk );
  41. STDMETHOD_(ULONG, AddRef) (THIS);
  42. STDMETHOD_(ULONG, Release) (THIS);
  43. //
  44. // ICiCLangRes methods
  45. //
  46. STDMETHOD(GetWordBreaker) ( LCID locale, PROPID pid, IWordBreaker ** ppWordBreaker )
  47. {
  48. return _langRes.GetWordBreaker(locale, pid, ppWordBreaker );
  49. }
  50. STDMETHOD(GetStemmer) ( LCID locale, PROPID pid, IStemmer ** ppStemmer )
  51. {
  52. return _langRes.GetStemmer(locale, pid, ppStemmer);
  53. }
  54. STDMETHOD(GetNoiseWordList) ( LCID locale, PROPID pid, IStream ** ppIStrmNoiseFile )
  55. {
  56. return _langRes.GetNoiseWordList( locale, pid, ppIStrmNoiseFile );
  57. }
  58. private:
  59. LONG _refCount;
  60. CLangRes _langRes;
  61. };