Be able to query methods parameters types
NDepend code model should propose a getter IType[] IMethods.ParametersTypes to be able to write certain code queries and rules, like security related ones.
42
votes
![](https://secure.gravatar.com/avatar/49116fb31985a387cbf514779e476d9b?size=40&default=https%3A%2F%2Fassets.uvcdn.com%2Fpkg%2Fadmin%2Ficons%2Fuser_70-6bcf9e08938533adb9bac95c3e487cb2a6d4a32f890ca6fdc82e3072e0ea0368.png)
-
Thomas Levesque commented
Not just the type, but also more information about parameters (name, type, attributes, ref/out...)
-
Anonymous commented
We use the NotNull and CanBeNull attributes to inform ReSharper null reference analysis. It would be great to use NDepend to enforce a rule that e.g. all constructor parameters for reference types are explicitly tagged as NotNull or CanBeNull.