I try to access all attributes of the given method from any classes into the WMI.
For example, I can list the methods inside "Win32_SystemDriver " class
Get-WmiObject -Class Win32_SystemDriver -List | Select -ExpandProperty Methods
Name InParameters OutParameters Origin Qualifiers
---- ------------ ------------- ------ ----------
StartService System.Management.ManagementBaseObject CIM_Service {MappingStrings, Override, ValueMap}
StopService System.Management.ManagementBaseObject CIM_Service {MappingStrings, Override, ValueMap}
PauseService System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
ResumeService System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
InterrogateService System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
UserControlService System.Management.ManagementBaseObject System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
Create System.Management.ManagementBaseObject System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, Static, ValueMap}
Change System.Management.ManagementBaseObject System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
ChangeStartMode System.Management.ManagementBaseObject System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
Delete System.Management.ManagementBaseObject Win32_BaseService {MappingStrings, ValueMap}
In MSDN document, Create method of the Win32_SystemDriver class has many attributes like;
uint32 Create(
[in] string Name,
[in] string DisplayName,
[in] string PathName,
[in] uint8 ServiceType,
[in] uint8 ErrorControl,
[in] string StartMode,
[in] boolean DesktopInteract,
[in] string StartName,
[in] string StartPassword,
[in] string LoadOrderGroup,
[in] string LoadOrderGroupDependencies[],
[in] string ServiceDependencies[]
);
Can I see these properties with CIM/WMI cmdlets? Also, if it is possible I want to see with their descriptions.
What you call "attributes" are parameters that are passed to the
Create()method. Those parameters are displayed in theDefinitionproperty of theCreate()member if you runGet-Member:If you want it as a list we can use Doug's Regex pattern:
With some more parsing we can turn these into more readable/usable objects:
We also converted the
Typestrings to[System.Type]objects.