PSCodeMethod(String, MethodInfo) Constructor

Definition

Initializes a new instance of the PSCodeMethod class.

public:
 PSCodeMethod(System::String ^ name, System::Reflection::MethodInfo ^ codeReference);
public PSCodeMethod (string name, System.Reflection.MethodInfo codeReference);
new System.Management.Automation.PSCodeMethod : string * System.Reflection.MethodInfo -> System.Management.Automation.PSCodeMethod
Public Sub New (name As String, codeReference As MethodInfo)

Parameters

name
String

name of the property

codeReference
MethodInfo

this should be a public static method where the first parameter is an PSObject.

Exceptions

for invalid arguments

if the codeReference does not have the right format

Applies to