PostSharp.ILAPI ReferencePost­Sharp.​ReflectionReflection­SearchGet­Methods­Using­Declaration
Open sandboxFocus

ReflectionSearch.GetMethodsUsingDeclaration Method

GetMethodsUsingDeclaration(MemberInfo)

Gets the set of methods and constructors whose body references a given (Type, System.Reflection.FieldInfo, System.Reflection.MethodInfo or System.Reflection.ConstructorInfo).

Declaration
public static MethodUsageCodeReference[] GetMethodsUsingDeclaration(MemberInfo declaration)
Parameters
Type Name Description
MemberInfo declaration

The Type, System.Reflection.FieldInfo, System.Reflection.MethodInfo or System.Reflection.ConstructorInfo whose references are requested.

Returns
Type Description
MethodUsageCodeReference[]

An array of MethodUsageCodeReference containing one item for each method or constructor whose body references declaration.

GetMethodsUsingDeclaration(MemberInfo, ReflectionSearchOptions)

Gets the set of methods and constructors whose body references a given (Type, System.Reflection.FieldInfo, System.Reflection.MethodInfo or System.Reflection.ConstructorInfo).

Declaration
public static MethodUsageCodeReference[] GetMethodsUsingDeclaration(MemberInfo declaration, ReflectionSearchOptions options)
Parameters
Type Name Description
MemberInfo declaration

The Type, System.Reflection.FieldInfo, System.Reflection.MethodInfo or System.Reflection.ConstructorInfo whose references are requested.

ReflectionSearchOptions options

This parameter has no effect and is kept only for backwards compatibility.

Returns
Type Description
MethodUsageCodeReference[]

An array of MethodUsageCodeReference containing one item for each method or constructor whose body references declaration.