IGLib
1.5
The IGLib base library for development of numerical, technical and business applications.
|
Interface from which all reporters inherit. More...
Public Member Functions | |
void | Init () |
Initializes all error reporting delegates to default values and sets auxliary object to null. Auxiliary object Obj is set to null. More... | |
void | Init (object obj, ReportDelegate reportdelegate, ReportLocationDelegate locationdelegate, ReportMessageDelegate messagedelegate, ReserveReportErrorDelegate reservereportdelegate) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Delegates that are not specified are set to default values. More... | |
void | Init (object obj, ReportDelegate reportdelegate, ReportLocationDelegate locationdelegate, ReportMessageDelegate messagedelegate) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Reserve error reporting delegate is initialized to a default value. Delegates that are not specified are set to default values. More... | |
void | Init (object obj, ReportDelegate reportdelegate) |
Initializes the error reporter by the specified auxiliary object and the delegate to perform error reporting tasks. Reserve error reporting delegate is initialized to a default value. Delegates for assembling the error location string and error message string are set to their default values, which are adapted to console-like eror reporting systems. More... | |
void | Init (object obj, ReportDelegate reportdelegate, ReserveReportErrorDelegate reservereportdelegate) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Delegates for assembling the error locatin and error message string are set to their default values, which are adapted to console-like eror reporting systems. More... | |
void | ReadAppSettings (string groupname) |
Reads settings for a specified named group of reporters from the application configuration file. More... | |
void | ReadAppSettings () |
Reads common reporter settings (i.e. settings that are not assigned for any named group) from the application configuration file. More... | |
void | ReadAppSettings (string groupname, bool onlyonce) |
Reads settings for a specified named group of reporters from the application configuration file. More... | |
bool | AppSettingsRead () |
Returns a flag that tells whether general configuration settings (not belonging to any group) have already been read for this reporter. More... | |
bool | AppSettingsRead (string groupname) |
Returns a flag that tells whether configuration settings with a given group name have already been read for this reporter. More... | |
void | IncreaseDepth () |
Increases indentation level by 1. More... | |
void | IncreaseDepth (int numlevels) |
Increases indentation level by the specified number of levels (can be 0 or negative). More... | |
void | DecreaseDepth () |
Decreases indentation level by 1. More... | |
void | DecreaseDepth (int numlevels) |
Decreases indentation level by the specified number of levels (can be 0 or negative). More... | |
void | ResetLevels () |
Resets the various kinds of reporting levels to default values. More... | |
bool | DoReporting (ReportType reptype) |
Returns true if the report of a given type should be shown by user interface (according to ReportingLevel), and false if not. More... | |
bool | DoLogging (ReportType reptype) |
Returns true if the report of a given type should be logged in log files (according to ReportingLevel), and false if not. More... | |
bool | DoTracing (ReportType reptype) |
Returns true if the report of a given type should traced (according to ReportingLevel), and false if not. More... | |
void | Report (ReportType messagetype, string location, string message, Exception ex) |
Basic reporting method (overloaded). Launches an error report, a warning report or other kind of report/message. Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance. More... | |
void | Report (ReportType messagetype, string message, Exception ex) |
Launches a report. Predominantly for error and warning reports. More... | |
void | Report (ReportType messagetype, Exception ex, string location) |
Launches a report. Predominantly for error and warning reports. More... | |
void | Report (ReportType messagetype, Exception ex) |
Launches a report. Predominantly for error and warning reports. More... | |
void | Report (ReportType messagetype, string location, string message) |
Launches a report. More... | |
void | Report (ReportType messagetype, string message) |
Launches a report. More... | |
void | ReportError (string location, string message, Exception ex) |
Basic error reporting method (overloaded). Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance. More... | |
void | ReportError (string message, Exception ex) |
Launches an error report. More... | |
void | ReportError (Exception ex, string location) |
Launches an error report. More... | |
void | ReportError (Exception ex) |
Launches an error report. Predominantly for error and warning reports. More... | |
void | ReportError (string location, string message) |
Launches an error report. More... | |
void | ReportError (string message) |
Launches an error report. More... | |
void | ReportWarning (string location, string message, Exception ex) |
Basic warning reporting method (overloaded). Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance. More... | |
void | ReportWarning (string message, Exception ex) |
Launches a warning report. More... | |
void | ReportWarning (Exception ex, string location) |
Launches a warning report. More... | |
void | ReportWarning (Exception ex) |
Launches a warning report. Predominantly for error and warning reports. More... | |
void | ReportWarning (string location, string message) |
Launches a warning report. More... | |
void | ReportWarning (string message) |
Launches a warning report. More... | |
void | ReportInfo (Exception ex) |
Launches an info. More... | |
void | ReportInfo (string location, string message) |
Launches an info. More... | |
void | ReportInfo (string message) |
Launches an info. More... | |
Properties | |
bool | AppSettingsWarnings [get, set] |
Gets or sets the flag that specifies whether a warning message is launched when reading of application settings is attempted more than once for the same named group of settings. More... | |
bool | IsGlobal [get] |
Indicates whether the current reporter is used as a global reporter or not. More... | |
int | Depth [get, set] |
Gets or sets the current indentation level for on-line output. This should normally be done by calling IncreaseDepth() or DecreaseDepth(). More... | |
ReportLevel | ReportingLevel [get, set] |
Gets or sets level of output for reporting (console output, message boxes, etc.). More... | |
ReportLevel | LoggingLevel [get, set] |
Gets or sets level of output for logging (writing to log files). More... | |
ReportLevel | TracingLevel [get, set] |
Gets or sets trace level (for external trace systems). More... | |
bool | TreatError [get] |
Returns a boolean value indicating whether errors are treated by the reporter in its current state. More... | |
bool | TreatWarning [get] |
Returns a boolean value indicating whether warnings are treated by the reporter in its current state. More... | |
bool | TreatInfo [get] |
Returns a boolean value indicating whether info messages are treated by the reporter in its current state. More... | |
bool | TreatUndefined [get] |
Returns a boolean value indicating whether undefined messages with the lowest priority are treated by the reporter in its current state. More... | |
ReportLevel | Level [get, set] |
Gets the level with the lowesst priority (out of reporting, logging and tracing level), or sets all levels to the assigned level. More... | |
bool | this[ReportLevel level] [get, set] |
Indexer that returns true if messages of a given level are treated by the reporter (either by the reporting, logging or tracing part, according to the corresponding level states), or false if not (i.e. if all the levels are set lover than the index). In the case of assignment, when true is assigned, all levels that are set lower than the are set to index. Assignment with false should be used only exteptionally; but in this case all levels that are set higher or equal than the index are set one level below. More... | |
TraceSwitch | ReportingSwitch [get, set] |
Gets or sets the TraceSwitch that is synchronized with ReportingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the ReportingLevel, which will override its settings). More... | |
TraceSwitch | LoggingSwitch [get, set] |
Gets or sets the TraceSwitch that is synchronized with LoggingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the LoggingLevel, which will override its settings). More... | |
TraceSwitch | TracingSwitch [get, set] |
Gets or sets the TraceSwitch that is synchronized with TracingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the TracingLevel, which will override its settings). More... | |
object | Obj [get, set] |
Auxiliary object used by the delegates that perform error reporting. More... | |
object | lockobj [get] |
Object used for locking. More... | |
Interface from which all reporters inherit.
void IG.Lib.IReporterBase.Init | ( | ) |
Initializes all error reporting delegates to default values and sets auxliary object to null. Auxiliary object Obj is set to null.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Init | ( | object | obj, |
ReportDelegate | reportdelegate, | ||
ReportLocationDelegate | locationdelegate, | ||
ReportMessageDelegate | messagedelegate, | ||
ReserveReportErrorDelegate | reservereportdelegate | ||
) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Delegates that are not specified are set to default values.
obj | Auxiliary object that will be passed to error reporting delegates when called in local methods. |
reportdelegate | Delegates that is called to launc an error report. Methods of this class will pass to this class the auxiliary object, location strings assembled by the location assembling delegate, and error message string assembled by the error message delegate. |
locationdelegate | Delegate that is called to assemble the error location string. The Auxiliary object this.Obj will be internally passed to this delegate any time it is called. |
messagedelegate | Delegate that is called to assemble the error message (without decorations). The Auxiliary object this.Obj will be internally passed to this delegate any time it is called. |
reservereportdelegate | Delegate that is called to report exceptions that occur within error reporting methods. In particular, this must ne as bullet proof as possible. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Init | ( | object | obj, |
ReportDelegate | reportdelegate, | ||
ReportLocationDelegate | locationdelegate, | ||
ReportMessageDelegate | messagedelegate | ||
) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Reserve error reporting delegate is initialized to a default value. Delegates that are not specified are set to default values.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Init | ( | object | obj, |
ReportDelegate | reportdelegate | ||
) |
Initializes the error reporter by the specified auxiliary object and the delegate to perform error reporting tasks. Reserve error reporting delegate is initialized to a default value. Delegates for assembling the error location string and error message string are set to their default values, which are adapted to console-like eror reporting systems.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Init | ( | object | obj, |
ReportDelegate | reportdelegate, | ||
ReserveReportErrorDelegate | reservereportdelegate | ||
) |
Initializes the error reporter by the specified auxiliary object and delegates used to perform error reporting tasks. Delegates for assembling the error locatin and error message string are set to their default values, which are adapted to console-like eror reporting systems.
obj | Auxiliary object that will be passed to error reporting delegates when called in local methods. |
reportdelegate | Delegates that is called to launc an error report. Methods of this class will pass to this class the auxiliary object, location strings assembled by the location assembling delegate, and error message string assembled by the error message delegate. |
reservereportdelegate | Delegate that is called to report exceptions that occur within error reporting methods. In particular, this must ne as bullet proof as possible. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReadAppSettings | ( | string | groupname | ) |
Reads settings for a specified named group of reporters from the application configuration file.
groupname | Name of the group of reporters for which the settings apply. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReadAppSettings | ( | ) |
Reads common reporter settings (i.e. settings that are not assigned for any named group) from the application configuration file.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReadAppSettings | ( | string | groupname, |
bool | onlyonce | ||
) |
Reads settings for a specified named group of reporters from the application configuration file.
groupname | Name of the group of reporters for which the settings apply. |
onlyonce | If true then settings belonging to the specified group are read only once, otherwise the settings for this group can be read several times (this is seldom used). |
Implemented in IG.Lib.ReporterBase.
bool IG.Lib.IReporterBase.AppSettingsRead | ( | ) |
Returns a flag that tells whether general configuration settings (not belonging to any group) have already been read for this reporter.
Implemented in IG.Lib.ReporterBase.
bool IG.Lib.IReporterBase.AppSettingsRead | ( | string | groupname | ) |
Returns a flag that tells whether configuration settings with a given group name have already been read for this reporter.
groupname | Name of the settings group, null and "" are treated teh same (denoting the genraal group). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.IncreaseDepth | ( | ) |
Increases indentation level by 1.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.IncreaseDepth | ( | int | numlevels | ) |
Increases indentation level by the specified number of levels (can be 0 or negative).
numlevels | Number of levels by which indentation is increased. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.DecreaseDepth | ( | ) |
Decreases indentation level by 1.
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.DecreaseDepth | ( | int | numlevels | ) |
Decreases indentation level by the specified number of levels (can be 0 or negative).
numlevels | Number of levels by which indentation is decreased. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ResetLevels | ( | ) |
Resets the various kinds of reporting levels to default values.
Implemented in IG.Lib.ReporterBase.
bool IG.Lib.IReporterBase.DoReporting | ( | ReportType | reptype | ) |
Returns true if the report of a given type should be shown by user interface (according to ReportingLevel), and false if not.
reptype | Type of the report for which information is returned. |
Implemented in IG.Lib.ReporterBase.
bool IG.Lib.IReporterBase.DoLogging | ( | ReportType | reptype | ) |
Returns true if the report of a given type should be logged in log files (according to ReportingLevel), and false if not.
reptype | Type of the report for which information is returned. |
Implemented in IG.Lib.ReporterBase.
bool IG.Lib.IReporterBase.DoTracing | ( | ReportType | reptype | ) |
Returns true if the report of a given type should traced (according to ReportingLevel), and false if not.
reptype | Type of the report for which information is returned. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
string | location, | ||
string | message, | ||
Exception | ex | ||
) |
Basic reporting method (overloaded). Launches an error report, a warning report or other kind of report/message. Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance.
messagetype | The type of the report (e.g. Error, Warning, etc.). |
location | User-provided description of error location. |
message | User-provided description of error. |
ex | Exception thrown when error occurred. |
Implemented in IG.Lib.ReporterBase, IG.Forms.ReporterForms, IG.Forms.ReporterConsoleMsgbox_Base, IG.Lib.ReporterConsoleMsgboxSpeech_Base, and IG.Lib.ReporterConsole_Base.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
string | message, | ||
Exception | ex | ||
) |
Launches a report. Predominantly for error and warning reports.
messagetype | Level of the message (Error, Warnind, etc.). |
message | User-provided description of error. |
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
Exception | ex, | ||
string | location | ||
) |
Launches a report. Predominantly for error and warning reports.
messagetype | Level of the message (Error, Warnind, etc.). |
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
location | User-provided description of error location. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
Exception | ex | ||
) |
Launches a report. Predominantly for error and warning reports.
messagetype | Level of the message (Error, Warnind, etc.). |
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
string | location, | ||
string | message | ||
) |
Launches a report.
messagetype | Level of the message (Error, Warnind, etc.). |
location | User provided description of the location where report was triggered. |
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.Report | ( | ReportType | messagetype, |
string | message | ||
) |
Launches a report.
messagetype | Level of the message (Error, Warnind, etc.). |
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | string | location, |
string | message, | ||
Exception | ex | ||
) |
Basic error reporting method (overloaded). Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance.
location | User-provided description of error location. |
message | User-provided description of error. |
ex | Exception thrown when error occurred. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | string | message, |
Exception | ex | ||
) |
Launches an error report.
message | User-provided description of error. |
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | Exception | ex, |
string | location | ||
) |
Launches an error report.
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
location | User-provided description of error location. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | Exception | ex | ) |
Launches an error report. Predominantly for error and warning reports.
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | string | location, |
string | message | ||
) |
Launches an error report.
location | User provided description of the location where report was triggered. |
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportError | ( | string | message | ) |
Launches an error report.
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | string | location, |
string | message, | ||
Exception | ex | ||
) |
Basic warning reporting method (overloaded). Supplemental data (such as objects necessary to launch visualize the report or operation flags) are obtained from the class' instance.
location | User-provided description of error location. |
message | User-provided description of error. |
ex | Exception thrown when error occurred. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | string | message, |
Exception | ex | ||
) |
Launches a warning report.
message | User-provided description of error. |
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | Exception | ex, |
string | location | ||
) |
Launches a warning report.
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
location | User-provided description of error location. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | Exception | ex | ) |
Launches a warning report. Predominantly for error and warning reports.
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | string | location, |
string | message | ||
) |
Launches a warning report.
location | User provided description of the location where report was triggered. |
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportWarning | ( | string | message | ) |
Launches a warning report.
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportInfo | ( | Exception | ex | ) |
Launches an info.
ex | Exception that is the cause for launching the report (and from which additional information is extracted). |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportInfo | ( | string | location, |
string | message | ||
) |
Launches an info.
location | User provided description of the location where report was triggered. |
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
void IG.Lib.IReporterBase.ReportInfo | ( | string | message | ) |
Launches an info.
message | User provided message included in the report. |
Implemented in IG.Lib.ReporterBase.
|
getset |
Gets or sets the flag that specifies whether a warning message is launched when reading of application settings is attempted more than once for the same named group of settings.
|
get |
Indicates whether the current reporter is used as a global reporter or not.
This flag is set when the global reporter is initialized.
|
getset |
Gets or sets the current indentation level for on-line output. This should normally be done by calling IncreaseDepth() or DecreaseDepth().
|
getset |
Gets or sets level of output for reporting (console output, message boxes, etc.).
|
getset |
Gets or sets level of output for logging (writing to log files).
|
getset |
Gets or sets trace level (for external trace systems).
|
get |
Returns a boolean value indicating whether errors are treated by the reporter in its current state.
|
get |
Returns a boolean value indicating whether warnings are treated by the reporter in its current state.
|
get |
Returns a boolean value indicating whether info messages are treated by the reporter in its current state.
|
get |
Returns a boolean value indicating whether undefined messages with the lowest priority are treated by the reporter in its current state.
|
getset |
Gets the level with the lowesst priority (out of reporting, logging and tracing level), or sets all levels to the assigned level.
|
getset |
Indexer that returns true if messages of a given level are treated by the reporter (either by the reporting, logging or tracing part, according to the corresponding level states), or false if not (i.e. if all the levels are set lover than the index). In the case of assignment, when true is assigned, all levels that are set lower than the are set to index. Assignment with false should be used only exteptionally; but in this case all levels that are set higher or equal than the index are set one level below.
level | Level for which we are interested whether it is treated. |
|
getset |
Gets or sets the TraceSwitch that is synchronized with ReportingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the ReportingLevel, which will override its settings).
|
getset |
Gets or sets the TraceSwitch that is synchronized with LoggingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the LoggingLevel, which will override its settings).
|
getset |
Gets or sets the TraceSwitch that is synchronized with TracingLevel. IMPORTANT: State of the object obtained by get accessor must not be changed unless the object is assigned back by the set accessor. If one wants that this TraceSwitch assumes values specified by the configuration file, a corresponding Traceswitch must be created and assigned to this property (otherwise the TraceSwitch will be synchronized with the TracingLevel, which will override its settings).
|
getset |
Auxiliary object used by the delegates that perform error reporting.
The object is used to provide additional information used in error reporting, or to provide objects that perform some actions in error reporting tasks, or both. It is left entirely to error reporting delegates to interpret the object's contents.
|
get |
Object used for locking.