x4Trace Documentation v1.0
Loading...
Searching...
No Matches
Tools.Assembly.AssemblyNameDictionary Class Reference

Represents a type dictionary by name. More...

Public Member Functions

 AssemblyNameDictionary ()
 Constructor.
 
List< Type > GetAvailableTypes ()
 Returns the list of types.
 
object Create (string name)
 Creates the instance by name.
 
Type GetT (string name)
 Gets a type by name.
 
void LoadByClassName (System.Reflection.Assembly sourceDLL, Type typeKey)
 Loads types from DLL. The inherited classes from type will be loaded.
 
void Load (System.Reflection.Assembly sourceDLL, Type typeKey)
 Loads types from DLL. The inherited classes from type will be loaded.
 

Events

GetTypeNameEvt GetTypeNameEvt = null
 Naming event of type. You can rename the element of dictionary.
 

Private Attributes

Dictionary< string, Type > typeDictionary
 Dictionary of types.
 

Detailed Description

Represents a type dictionary by name.

Member Function Documentation

◆ Create()

object Tools.Assembly.AssemblyNameDictionary.Create ( string name)

Creates the instance by name.

Parameters
nameName of type.
Returns
The created object.
Exceptions
TypeNotFoundExceptionThrows exception when the type is missing.

◆ GetAvailableTypes()

List< Type > Tools.Assembly.AssemblyNameDictionary.GetAvailableTypes ( )

Returns the list of types.

Returns
List of types.

◆ GetT()

Type Tools.Assembly.AssemblyNameDictionary.GetT ( string name)

Gets a type by name.

Parameters
nameName of type.
Returns
The type.
Exceptions
TypeNotFoundExceptionThrows exception when the type is missing.

◆ Load()

void Tools.Assembly.AssemblyNameDictionary.Load ( System.Reflection.Assembly sourceDLL,
Type typeKey )

Loads types from DLL. The inherited classes from type will be loaded.

Parameters
sourceDLLSource DLL.
typeKeyInherited type of classes to load.
Exceptions
ExceptionThrows when type is duplicated.

◆ LoadByClassName()

void Tools.Assembly.AssemblyNameDictionary.LoadByClassName ( System.Reflection.Assembly sourceDLL,
Type typeKey )

Loads types from DLL. The inherited classes from type will be loaded.

Parameters
sourceDLLSource DLL.
typeKeyInherited type of classes to load.

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