원시 및 형식이 지정된 성능 데이터 개체에 대한 설명서 검색
다음 항목에서는 동적으로 생성된 원시 데이터 개체 또는 형식이 지정된 데이터 개체에 대한 온라인 프로그래밍 설명서를 검색하는 방법에 대해 설명합니다.
WMI에는 성능을 추적하는 여러 개체가 포함되어 있습니다. Win32_PerfRawData에서 파생된 클래스는 원시 또는 ‘조리되지 않은’ 성능 데이터를 포함하며 성능 카운터 공급자가 지원합니다. 반면, Win32_PerfFormattedData에서 파생된 클래스는 ‘cooked’ 또는 형식이 지정된 데이터를 포함하며 형식이 지정된 성능 데이터 공급자에서 지원됩니다.
그러나 두 공급자는 모두 동적으로 생성된 여러 자식 클래스를 지원합니다. 속성은 런타임에 추가되므로 이러한 클래스에는 문서화되지 않은 속성이 포함될 수 있습니다. 다음 코드를 사용하여 지정된 동적으로 만든 클래스에 있는 속성을 식별할 수 있습니다.
동적으로 생성된 클래스에 대한 설명을 검색하려면
해당 항목의 인스턴스를 만들고 수정된 한정자를 true로 설정합니다.
$osClass = New-Object System.Management.ManagementClass Win32_ClassNameHere $osClass.Options.UseAmendedQualifiers = $true
클래스의 속성을 검색합니다.
$properties = $osClass.Properties "This class has {0} properties as follows:" -f $properties.count
속성을 표시합니다.
foreach ($property in $properties) { "Property Name: {0}" -f $property.Name "Description: {0}" -f $($property.Qualifiers["Description"].Value) "Type: {0}" -f $property.Type "-------" }
다음 코드는 지정된 Win32_PerfFormattedData 개체에 대한 속성 설명을 검색합니다.
$osClass = New-Object System.Management.ManagementClass Win32_PerfFormattedData_APPPOOLCountersProvider_APPPOOLWAS
$osClass.Options.UseAmendedQualifiers = $true
# Get the Properties in the class
$properties = $osClass.Properties
"This class has {0} properties as follows:" -f $properties.count
# display the Property name, description, type, qualifiers and instance values
foreach ($property in $properties) {
"Property Name: {0}" -f $property.Name
"Description: {0}" -f $($property.Qualifiers["Description"].Value)
"Type: {0}" -f $property.Type
"-------"
}
피드백
https://aka.ms/ContentUserFeedback
출시 예정: 2024년 내내 콘텐츠에 대한 피드백 메커니즘으로 GitHub 문제를 단계적으로 폐지하고 이를 새로운 피드백 시스템으로 바꿀 예정입니다. 자세한 내용은 다음을 참조하세요.다음에 대한 사용자 의견 제출 및 보기