MetalamaAPI documentationPost­Sharp API migrationPost­Sharp.​ReflectionReflection­SearchGet­Declarations­Used­By­Method
Open sandboxFocus

ReflectionSearch.GetDeclarationsUsedByMethod Method

GetDeclarationsUsedByMethod(MethodBase)

In Metalama, the feature is not exposed on the code model, but it is a part of the validation feature thanks to the ValidateReferences<TValidator>(Func<TDeclaration, TValidator>) method.

Declaration
public static MethodUsageCodeReference[] GetDeclarationsUsedByMethod(MethodBase method)
Parameters
Type Name Description
System.Reflection.MethodBase method
Returns
Type Description
MethodUsageCodeReference[]
See Also

GetDeclarationsUsedByMethod(MethodBase, ReflectionSearchOptions)

In Metalama, the feature is not exposed on the code model, but it is a part of the validation feature thanks to the ValidateReferences<TValidator>(Func<TDeclaration, TValidator>) method.

Declaration
public static MethodUsageCodeReference[] GetDeclarationsUsedByMethod(MethodBase method, ReflectionSearchOptions options)
Parameters
Type Name Description
System.Reflection.MethodBase method
ReflectionSearchOptions options
Returns
Type Description
MethodUsageCodeReference[]
See Also