Table of Contents

Method GetTypesSafe

Namespace
Alternet.UI
Assembly
Alternet.UI.Common.dll

GetTypesSafe(Assembly?, bool)

Returns the types defined in the specified assembly, optionally including only the exported types.

public static Type[] GetTypesSafe(Assembly? asm, bool onlyExported)

Parameters

asm Assembly

The assembly from which to retrieve types. Can be null.

onlyExported bool

true to return only types that are exported from the assembly; otherwise, false to return all types.

Returns

Type[]

An array of Type objects representing the types defined in the assembly. Returns an empty array if the assembly is null or contains no matching types.

GetTypesSafe(Assembly?)

Safely retrieves all types defined in the specified assembly.

public static Type[] GetTypesSafe(Assembly? asm)

Parameters

asm Assembly

The assembly to retrieve types from.

Returns

Type[]

An array of Type objects representing the types defined in the assembly. Returns an empty array if the assembly is null or an error occurs while retrieving the types.