In continuation to the previous post on getting all overload signature of an object’s method, you would notice that we do not get any help regarding the number and overload for an type’s constructor. To view the overloads of a type constructor, below script can be used.

Const1

The above can also be re-written more succinctly using pipelines as shown below..

Const2

the results should look like below..

Const result

This would help you in knowing which constructor to use while creating new objects of a type.

Hope this helps!!

Cheers!!

Leave a comment