Source code of Windows XP (NT5)
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.

76 lines
2.0 KiB

  1. ///////////////////////////////////////////////////////////////////////////////
  2. // hashstring.idl
  3. //
  4. // ABSTRACT:
  5. // Contains interface definition for IStringTable. This implementer maintains a
  6. // key/value pair of BSTR string values for lookup by any caller.
  7. //
  8. // HISTORY:
  9. // 05/12/00 - created (cfeller)
  10. ///////////////////////////////////////////////////////////////////////////////
  11. import "oaidl.idl";
  12. import "ocidl.idl";
  13. [
  14. object,
  15. uuid(20FDEBA0-E15A-42DA-9E3F-B5A5619E5229),
  16. helpstring("IStringTable Interface"),
  17. pointer_default(unique)
  18. ]
  19. interface IStringTable : IUnknown
  20. {
  21. // Load strings from the given ini file section. Ini file must be in the form of:
  22. //
  23. // [THE_SECTION_NAME]
  24. // Name1=Value1
  25. // Name2=Value2
  26. //
  27. // NOTE: The total number characters in the entire section must not exceed 8192.
  28. HRESULT LoadStringsFromFile([in] BSTR szConfigurationFilePath, [in] BSTR szIniSection);
  29. // Store a new string value in the component.
  30. HRESULT AddString([in] BSTR szKey, [in] BSTR szValue);
  31. // Store a new numeric value in the component.
  32. HRESULT AddNumber([in] BSTR szKey, [in] long lValue);
  33. // Retrieve the stored value identified by the given key.
  34. //
  35. // NOTE: Returns a copy of the data...NOT the original. Caller is responsible for
  36. // freeing the allocated copy.
  37. HRESULT LookupString([in] BSTR szKey, [out,retval] BSTR* pbstrValue);
  38. // Retrieve the stored value identified by the given key.
  39. //
  40. HRESULT LookupNumber([in] BSTR szKey, [out,retval] long* plValue);
  41. // Remove all strings stored by the component
  42. HRESULT ClearStrings();
  43. };
  44. [
  45. uuid(D16D0A7E-DB9A-4080-8CB6-D5FD6AE17269),
  46. version(1.0),
  47. helpstring("HashString 1.0 Type Library")
  48. ]
  49. library HASHSTRINGLib
  50. {
  51. importlib("stdole32.tlb");
  52. importlib("stdole2.tlb");
  53. import "passportservice.idl";
  54. [
  55. uuid(5769ACF1-99C7-45BE-BC9B-A54A6648FD05),
  56. helpstring("StringTable Class")
  57. ]
  58. coclass StringTable
  59. {
  60. [default] interface IStringTable;
  61. interface IPassportService;
  62. };
  63. };
  64. ////////////
  65. // EOF
  66. ////////////