OpenPetra
Free Administration Software for Non-Profits
Ict.Common.ErrorCodeInventory Class Reference

Inventory functions for the OpenPetra Error Codes. More...

Static Public Member Functions

static void Init ()
 make sure we have empty static variables at the start of each web request More...
 
static ErrCodeInfo RetrieveErrCodeInfo (string AErrorCode)
 Retrieves the ErrCodeInfo for a given Error Code. More...
 
static string ListRegisteredTypes ()
 Lists the Types that are registered to contain Error Codes. More...
 
static void BuildErrorCodeInventory (Type AErrorCodesType)
 Populates the Dictionary ErrorCodeCatalogue from all public Constants of the Type that is passed in. More...
 

Static Public Attributes

static Dictionary< string, ErrCodeInfoErrorCodeCatalogue = null
 Catalogue of all OpenPetra Error Codes. More...
 
static List< Type > RegisteredTypes = null
 Contains all Types which are registered to contain Error Code constants. More...
 

Detailed Description

Inventory functions for the OpenPetra Error Codes.

Member Function Documentation

◆ BuildErrorCodeInventory()

static void Ict.Common.ErrorCodeInventory.BuildErrorCodeInventory ( Type  AErrorCodesType)
inlinestatic

Populates the Dictionary ErrorCodeCatalogue from all public Constants of the Type that is passed in.

Parameters
AErrorCodesTypeType that contains public error Constants.

◆ Init()

static void Ict.Common.ErrorCodeInventory.Init ( )
inlinestatic

make sure we have empty static variables at the start of each web request

◆ ListRegisteredTypes()

static string Ict.Common.ErrorCodeInventory.ListRegisteredTypes ( )
inlinestatic

Lists the Types that are registered to contain Error Codes.

Returns
Types that are registered to contain Error Codes, sepearated by semicolons.

◆ RetrieveErrCodeInfo()

static ErrCodeInfo Ict.Common.ErrorCodeInventory.RetrieveErrCodeInfo ( string  AErrorCode)
inlinestatic

Retrieves the ErrCodeInfo for a given Error Code.

Parameters
AErrorCodeError Code.
Returns
ErrCodeInfo for the Error Code specified in AErrorCode or null if the Error Code isn't found in any of the registered Types or in the calling Class.

Member Data Documentation

◆ ErrorCodeCatalogue

Dictionary<string, ErrCodeInfo> Ict.Common.ErrorCodeInventory.ErrorCodeCatalogue = null
static

Catalogue of all OpenPetra Error Codes.

Automatically created from all the public Constants of the Ict.Common.CommonErrorCodes Class and the 'Ict.Petra.Shared.PetraErrorCodes' Class when Method BuildErrorCodeInventory of this Class called!

◆ RegisteredTypes

List<Type> Ict.Common.ErrorCodeInventory.RegisteredTypes = null
static

Contains all Types which are registered to contain Error Code constants.

IMPORTANT: Only Error Code Constants of Types which are registered can be used with Method M:ErrorCodes.GetErrorInfo(string)!


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