TRttiObjectHelper.TryGetCustomAttribute<T> Method

Overloads

TryGetCustomAttribute(TAttributeClass, TCustomAttribute, Boolean)
TryGetCustomAttribute<T>(T, Boolean)

Try getting a custom attribute class which is applied by the type.

TryGetCustomAttribute(TAttributeClass, TCustomAttribute, Boolean)

Delphi
function TryGetCustomAttribute(attributeClass: TAttributeClass; out attribute: TCustomAttribute; inherit: Boolean = False): Boolean

Parameters

attributeClass
TAttributeClass
attribute
TCustomAttribute
inherit
Boolean

Returns

Boolean

TryGetCustomAttribute<T>(T, Boolean)

Try getting a custom attribute class which is applied by the type.

Delphi
function TryGetCustomAttribute<T>(out attribute: T; inherit: Boolean = False): Boolean

Type Parameters

T

Parameters

attribute
T
inherit
Boolean

Returns

Boolean