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.

154 lines
4.0 KiB

  1. [WMI, guid("{F883CBB0-CCA4-11d0-A4F8-00A0C9062910}")]
  2. class UnicodeString
  3. {
  4. [read, Id(1)]
  5. short Length;
  6. [read, Id(2), WmiSizeIs("Length")]
  7. short String[];
  8. };
  9. //
  10. // Standard class for reporting serial port information
  11. //
  12. [WMI, guid("{85F64E01-5A9B-11d0-A838-00AA0060D45C}"),
  13. locale("ms\\0x409"),
  14. WmiHelp009("English.hlp"),
  15. WmiHelp010("French.hlp"),
  16. WmiBaseHelpId(0x20),
  17. WmiClassHelpId(0x1f),
  18. WmiExpense(1)]
  19. class StandardSerialInformation
  20. {
  21. //
  22. // InstanceName and Active are the required properties for WBEM to be able to
  23. // manage WMI data blocks. The must not have Id's associated with them.
  24. [key, read]
  25. UnicodeString embedding InstanceName; // Instance name returned from WMI
  26. [read]
  27. boolean Active;
  28. //
  29. // This is the first data item in the blob and is a 64 bit integer and is readonly
  30. [read,
  31. Id(1),
  32. WmiScale(0),
  33. WmiCounterType(0x00000000),
  34. WmiComplexity(1),
  35. WmiVolatility(1000)]
  36. uint64 BytesSent; // bytes sent on port
  37. //
  38. // This is the second data item in the blob and is also a 64 bit integer and is
  39. // readable or writable.
  40. [read,
  41. write,
  42. Id(2),
  43. WmiScale(0),
  44. WmiCounterType(0x00000000),
  45. WmiVolatility(1000)]
  46. uint64 BytesReceived; // Bytes received on port
  47. //
  48. // This data item is only present in version 2 or higher of the data block and is the
  49. // fourth data item in the data block. It is a read only counted unicode string.
  50. [read,
  51. WmiVersion(2),
  52. Id(4),
  53. WmiScale(0),
  54. WmiCounterType(0x00000b00),
  55. WmiVolatility(60000)]
  56. UnicodeString embedding Owner; // Who owns the port
  57. //
  58. // This is the third data item in the data block and is part of version 1 and higher
  59. // of the data block. It is a fixed length array of 16 bytes. Note that the order in
  60. // the MOF class definition is not relevant to the order in the data block
  61. [read, write,
  62. Id(3),
  63. WmiScale(0),
  64. WmiCounterType(0x00000300)]
  65. byte Status[/*16*/]; // Status bit array
  66. //
  67. // This the fifth data item in the data block and is only in version 3 and higher
  68. // of the data block.
  69. [read,
  70. Id(5),
  71. WmiVersion(3),
  72. WmiScale(0),
  73. WmiCounterType(0x00000000),
  74. WmiComplexity(1),
  75. WmiVolatility(1000)]
  76. uint32 XmitDescriptorCount;
  77. //
  78. // This the sixth data item in the data block and is only in version 3 and higher
  79. // of the data block. It is a variable length array of XmitDescriptor structures.
  80. // The number of elements in the array can be found in the XmitDescriptorCount
  81. // property.
  82. [read,
  83. Id(6),
  84. WmiSizeIs("XmitDescriptorCount"),
  85. WmiScale(0),
  86. WmiCounterType(0x00000000),
  87. WmiComplexity(1),
  88. WmiVolatility(1000)]
  89. XmitDescriptor embedding XmitBufferSize[];
  90. };
  91. [WMI, guid("{F883CBB1-CCA4-11d0-A4F8-00A0C9062910}")]
  92. class XmitDescriptor
  93. {
  94. [read, Id(1)] int32 DestinationIndex;
  95. [read, Id(2)] int32 DestinationTarget;
  96. };
  97. [guid("{85F64E02-5A9B-11d0-A838-00AA0060D45C}"),
  98. locale("ms\\0x409"),
  99. WmiHelp009("English.hlp"),
  100. WmiHelp010("French.hlp"),
  101. WmiBaseHelpId(0x20),
  102. WmiClassHelpId(0x1f),
  103. WmiExpense(1),
  104. WmiEvent]
  105. class SerialSendEvent
  106. {
  107. //
  108. // InstanceName and Active are the required properties for WBEM to be able to
  109. // manage WMI data blocks. The must not have Id's associated with them.
  110. [key, read]
  111. UnicodeString embedding InstanceName;
  112. [read]
  113. boolean Active;
  114. //
  115. // This data item is an event that can be enabled by a data consumer. The
  116. // SendEventTrigger data item can be used to set or read the trigger for event
  117. // generation while the SendEventRate data item can be set or read to regulate the
  118. // event generation rate.
  119. [read,
  120. Id(1),
  121. WmiScale(0),
  122. WmiCounterType(0x00000000),
  123. WmiEvent,
  124. WmiEventTrigger("SendEventTrigger"),
  125. WmiEventRate("SendEventRate")]
  126. int32 SendEventValue;
  127. [read,
  128. write,
  129. Id(2)]
  130. int32 SendEventRate;
  131. [read,
  132. write,
  133. Id(3)]
  134. int32 SendEventTrigger;
  135. };