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.

103 lines
2.6 KiB

  1. /*++
  2. Copyright (c) 1997-1999 Microsoft Corporation
  3. Revision History:
  4. --*/
  5. //
  6. // Is the registration of the view namespace and view provider required of
  7. // every mof or can it be done by WMI setup ????
  8. //
  9. #pragma namespace("\\\\.\\root")
  10. instance of __Namespace
  11. {
  12. Name = "ViewNamespace" ;
  13. };
  14. #pragma namespace("\\\\.\\root\\viewnamespace")
  15. instance of __Win32Provider as $DataProv
  16. {
  17. Name = "MS_VIEW_INSTANCE_PROVIDER";
  18. ClsId = "{AA70DDF4-E11C-11D1-ABB0-00C04FD9159E}";
  19. ImpersonationLevel = 1;
  20. PerUserInitialization = "True";
  21. };
  22. instance of __InstanceProviderRegistration
  23. {
  24. Provider = $DataProv;
  25. SupportsPut = True;
  26. SupportsGet = True;
  27. SupportsDelete = True;
  28. SupportsEnumeration = True;
  29. QuerySupportLevels = {"WQL:UnarySelect"};
  30. };
  31. instance of __MethodProviderRegistration
  32. {
  33. Provider = $DataProv;
  34. };
  35. //
  36. // End view provider registration
  37. //
  38. // Keyboard device extension class
  39. //
  40. [
  41. Dynamic,
  42. Provider("MS_VIEW_INSTANCE_PROVIDER"),
  43. ViewSpaces{"\\\\.\\root\\wmi",
  44. "\\\\.\\root\\wmi",
  45. "\\\\.\\root\\cimv2"},
  46. ViewSources{"Select InstanceName, DataQueueSize, ErrorCount, Indicators, FunctionKeys from MSKeyboard_PortInformation",
  47. "Select InstanceName, PnPDeviceId from MSWmi_PnPDeviceId",
  48. "Select PNPDeviceId, NumberOfFunctionKeys from Win32_Keyboard"},
  49. JoinOn("Win32_Keyboard.PNPDeviceId = MSWmi_PnPDeviceId.PnPDeviceId and MSKeyboard_PortInformation.InstanceName = MSWmi_PnPDeviceId.InstanceName")
  50. ]
  51. class Win32_KeyboardExtension
  52. {
  53. [PropertySources{"InstanceName", "", ""},key]
  54. string WdmKeyboardInstanceName;
  55. [PropertySources{"", "InstanceName", ""},key]
  56. string WdmPnPInstanceName;
  57. [PropertySources{"", "PnPDeviceId", ""}]
  58. string WdmPnPDeviceId;
  59. [PropertySources{"", "", "PNPDeviceId"}, key]
  60. string CimPnPDeviceId;
  61. [PropertySources{"DataQueueSize", "", ""},
  62. Description("The DataQueueSize property indicates the size of the data queue.")
  63. ]
  64. uint32 DataQueueSize;
  65. [PropertySources{"ErrorCount", "", ""},
  66. Description("Number of errors that occured on this device")
  67. ]
  68. uint32 ErrorCount;
  69. [PropertySources{"Indicators", "", ""},
  70. Description("The NumberOfIndicators property indicates the number of indicator leds on the keyboard.")
  71. ]
  72. uint32 Indicators;
  73. [PropertySources{"FunctionKeys", "", ""},
  74. Description("The NumberOfFunctionKeys property indicates the number of function keys on the keyboard.")
  75. ]
  76. uint32 WdmFunctionKeys;
  77. [PropertySources{"", "", "NumberOfFunctionKeys"}
  78. ]
  79. uint16 CimFunctionKeys;
  80. };