EGDL2 2.1
Loading...
Searching...
No Matches
FullSerializer.Internal.fsPortableReflection Class Reference

This wraps reflection types so that it is portable across different Unity runtimes. More...

Static Public Member Functions

static bool HasAttribute (MemberInfo element, Type attributeType)
 Returns true if the given attribute is defined on the given element.
 
static bool HasAttribute< TAttribute > (MemberInfo element)
 Returns true if the given attribute is defined on the given element.
 
static Attribute GetAttribute (MemberInfo element, Type attributeType)
 Fetches the given attribute from the given MemberInfo. This method applies caching and is allocation free (after caching has been performed).
 
static TAttribute GetAttribute< TAttribute > (MemberInfo element)
 Fetches the given attribute from the given MemberInfo.
 

Detailed Description

This wraps reflection types so that it is portable across different Unity runtimes.

Member Function Documentation

◆ GetAttribute()

static Attribute FullSerializer.Internal.fsPortableReflection.GetAttribute ( MemberInfo element,
Type attributeType )
inlinestatic

Fetches the given attribute from the given MemberInfo. This method applies caching and is allocation free (after caching has been performed).

Parameters
elementThe MemberInfo the get the attribute from.
attributeTypeThe type of attribute to fetch.
Returns
The attribute or null.
Here is the caller graph for this function:

◆ GetAttribute< TAttribute >()

static TAttribute FullSerializer.Internal.fsPortableReflection.GetAttribute< TAttribute > ( MemberInfo element)
inlinestatic

Fetches the given attribute from the given MemberInfo.

Template Parameters
TAttributeThe type of attribute to fetch.
Parameters
elementThe MemberInfo to get the attribute from.
Returns
The attribute or null.
Type Constraints
TAttribute :Attribute 
Here is the call graph for this function:

The documentation for this class was generated from the following file: