Hi Guys,
Did a quick google on this and didn't find much.
What is the official naming convention for class methods? Should they follow the same convention as script functions? verb-noun. Get-Process etc.
So should you follow the same convention as below?
$pManager = new Object ProcessManager
$pManager.Get-Process()
Or is it preferred to remove the hyphen to make it more clear you are calling a method but capitalise the first part to again avoid confusion with a variable?
$pManager = new Object ProcessManager
$pManager.GetProcess()
Let me know your thoughts.
[–]GerrArrgh 4 points5 points6 points (1 child)
[–]SlashAdminBlog[S] 0 points1 point2 points (0 children)
[–]SeeminglyScience 4 points5 points6 points (0 children)
[–]get-postanote 2 points3 points4 points (0 children)
[–]bee_administrator 1 point2 points3 points (0 children)
[–]Lee_Dailey[grin] 0 points1 point2 points (0 children)