Get-SCOMCommand
获取当前会话中的 Operations Manager 命令。
语法
CmdletSet (默认值)
Get-SCOMCommand
[-Verb <String[]>]
[-Noun <String[]>]
[<CommonParameters>]
AllCommandSet
Get-SCOMCommand
[[-Name] <String[]>]
[-CommandType <CommandTypes>]
[<CommonParameters>]
说明
Get-SCOMCommand cmdlet 获取当前会话中的 System Center - Operations Manager 命令。 如果未为 cmdlet 指定任何参数,该 cmdlet 将返回当前会话中的所有命令。
示例
示例 1:使用名称获取命令
PS C:\>Get-SCOMCommand "*agent*"
此命令获取 Operations Manager 模块中具有代理的命令名称中的所有命令。
示例 2:使用 cmdlet 谓词获取命令
PS C:\>Get-SCOMCommand -Verb "Get"
此命令获取使用谓词 Get 的 Operations Manager 模块中的所有命令。
参数
-CommandType
指定 Operations Manager 命令类型。
参数属性
| 类型: | CommandTypes |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
| 别名: | 类型 |
参数集
AllCommandSet
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | True |
| 来自剩余参数的值: | False |
-Name
指定 Operations Manager 命令的名称数组。
参数属性
| 类型: | String[] |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
AllCommandSet
| Position: | 1 |
| 必需: | False |
| 来自管道的值: | True |
| 来自管道的值(按属性名称): | True |
| 来自剩余参数的值: | False |
-Noun
指定 Operations Manager cmdlet 名称中的名词数组。
参数属性
| 类型: | String[] |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
CmdletSet
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | True |
| 来自剩余参数的值: | False |
-Verb
指定 Operations Manager cmdlet 名称中的谓词数组。
参数属性
| 类型: | String[] |
| 默认值: | None |
| 支持通配符: | False |
| 不显示: | False |
参数集
CmdletSet
| Position: | Named |
| 必需: | False |
| 来自管道的值: | False |
| 来自管道的值(按属性名称): | True |
| 来自剩余参数的值: | False |
CommonParameters
此 cmdlet 支持通用参数:-Debug、-ErrorAction、-ErrorVariable、-InformationAction、-InformationVariable、-OutBuffer、-OutVariable、-PipelineVariable、-ProgressAction、-Verbose、-WarningAction 和 -WarningVariable。 有关详细信息,请参阅 about_CommonParameters。