T
IdeaBlade DevForce 2010 Help Reference
GetAttribute<T>(Type,Boolean) Method
See Also  Send Feedback
IdeaBlade.Core Assembly > IdeaBlade.Core Namespace > ReflectionFns Class > GetAttribute Method : GetAttribute<T>(Type,Boolean) Method



type
checkMetadataType
Returns the first attribute of the given type on an object, or null if not found. Optionally check any metadata type associated with the specified type as well.

Syntax

Visual Basic (Declaration) 
<ObsoleteAttribute("The checkMetadataType parameter is obsolete and is no longer needed. Use an overload without this parameter. ")>
Public Overloads Shared Function GetAttribute(Of T As Attribute)( _
   ByVal type As Type, _
   ByVal checkMetadataType As Boolean _
) As T
Visual Basic (Usage)Copy Code
Dim type As Type
Dim checkMetadataType As Boolean
Dim value As T
 
value = ReflectionFns.GetAttribute(Of T)(type, checkMetadataType)
C# 
[ObsoleteAttribute("The checkMetadataType parameter is obsolete and is no longer needed. Use an overload without this parameter. ")]
public static T GetAttribute<T>( 
   Type type,
   bool checkMetadataType
)
where T: Attribute
C++/CLI 
[ObsoleteAttribute("The checkMetadataType parameter is obsolete and is no longer needed. Use an overload without this parameter. ")]
public:
static T^ GetAttributegeneric<typename T>
( 
   Type^ type,
   bool checkMetadataType
) 
where T: Attribute

Parameters

type
checkMetadataType

Type Parameters

T

Requirements

Target Platforms: Windows 98, Windows NT 4.0, Windows Millennium Edition, Windows 2000, Windows XP Home Edition, Windows XP Professional, Windows Server 2003 family, Windows Vista, Windows Server 2008 family

See Also

© 2013 All Rights Reserved.