UI Automation (both '1.0' and '2.0') is a complicated framework in terms of naming. Especially patterns that are classes, their lever could be a method, a property, both method and property, or even a set of methods and properties.
At the same time, Microsoft insists on naming cmdlet as Verb-Noun, its Cmdlet Design Guidelines requires the schema Verb-[YourCompany/Project]Noun.
Whereas many teams in Microsoft outside the PowerShell division don't follow these guidelines (especially, names of parameters deviate), and the PowerShell division published the first cmdlets (PS 1.0) before these guidelines were out, we amateurs struggle
to follow these guidelines. :)
Here are rules we followed in naming:
- Read- cmdlets return the properties of AutomationElement (i.e., the properties you could get via $element.Current, for example, AutomaitonId, ProcessId, AccessKey)
- patterns are Invoke- cmdlets (Invoke-UIA[PatternName]Pattern, Invoke-UIA[PatternName]PatternSet, Invoke-UIA[PatternName]PatternGet)
- for readability and searchability, there are cmdlets (just classes derived from Pattern- cmdlets) like Get-UIA[...]Value, Get-UIA[...]SelectionItem, etc
Regarding the topic you raised, this is definitely a bug.
Initially, the matrix which control should have such a pattern was pulled from MSDN. However, some controls in real life supported patterns that they weren't supposed to support (and a lot controls didn't support patterns they were supposed to suppport). After
all, there were 'invented' 'Custom' cmdlets: they are not ties to the type (Custom), it's just for readability.
There is the Get-UIAValuePatternGet (I just renamed it to Invoke-UIAValuePatternGet), but further is a mess-up.
Some cmdlets are 'Value', same are 'Text'.
Get-UIACustomValue is now Get-UIACustomText
I'll change some names of cmdlet today and publish one more beta. All old names will be marked obsolete, not removed.
For example, the following are new names of previously Get- (now obsolete) cmdlets:
Some other cmdlets (unpopular, as I think. I, for instance, never used in practice some patterns) are separated by the action they perform:
Invoke-UIADockPattern -> Invoke-UIADockPatternSet
Get-UIADockPattern -> Invoke-UIADockPatternGet
Thank you for pointing to the naming problem!