GenericTypeParameterBuilder.DeclaringType Property

 
System_CAPS_noteNote

The .NET API Reference documentation has a new home. Visit the .NET API Browser on docs.microsoft.com to see the new experience.

Gets the generic type definition or generic method definition to which the generic type parameter belongs.

Namespace:   System.Reflection.Emit
Assembly:  mscorlib (in mscorlib.dll)

public override Type DeclaringType { get; }

Property Value

Type: System.Type

If the type parameter belongs to a generic type, a Type object representing that generic type; if the type parameter belongs to a generic method, a Type object representing that type that declared that generic method.

The declaring type is not necessarily a generic type. If the current type parameter belongs to a generic method, the type in which the method is declared might not be generic.

.NET Framework
Available since 2.0
Silverlight
Available since 2.0
Return to top
Show: