Powershell - can INotifyPropertyChanged be implemented initially?

Does anyone know if the INotifyPropertyChanged interface can be implemented on an object in Powershell initially, without creating a C # class and using Add-Type to create a new .NET assembly?

I was looking for everything I could come up with, and could not find a solution.

Thanks.

+1
source share
1 answer

No. Consider the PowerShell CLI consumer language and not so much the producer language. That is, you can create and use most .NET types. However, PowerShell does not create the ability to create new .NET types, but there are much fewer types that implement interfaces. Although you can create custom objects in PowerShell and use tricks to give these objects a type name that PowerShell understands, these tricks do not work with .NET libraries such as WPF.

+1
source

All Articles