Open Stephanevg opened 5 years ago
Given the following powershell module
Enum ComputerType { Server Client } Class Computer { [String]$Name [ComputerType]$Type } Function Get-InternalStuff { #Does internal stuff } Function Get-ComputerData { #Does stuff } Export-ModuleMember -Function Get-ComputerData
Import-Module PsClassUtils Get-CUClass Name : ComputerType Property : {Server, Client} Constructor : Method : IsInherited : False ParentClassName : Path : C:\Users\taavast3\OneDrive\Repo\Projects\OpenSource\Stephanevg.github.io\_Drafts\plop.psm1 Name : Computer Property : {Name, Type} Constructor : Method : IsInherited : False ParentClassName : Path : C:\Users\taavast3\OneDrive\Repo\Projects\OpenSource\Stephanevg.github.io\_Drafts\plop.psm1
It should not Show the Enum.
An If Block is missing in Get-CUClass You should had the following If statement after the Foreach statement
Foreach ( $x in (Get-CULoadedClass @ClassParams ) ) { If ( !$x.IsEnum ){
Given the following powershell module
It should not Show the Enum.