MessageBase class | QSYS API Reference Guide
Estimated reading time: 2 minutes
Represents a base class for messages, providing properties and methods for message text, cause, recovery suggestions, and logging functionality.
Namespace: ASNA.QSys.Runtime.JobSupport Assembly: ASNA.QSys.Runtime.dll
Inheritance: Object
Properties
Type | Name | Description |
---|---|---|
String | Cause | Gets an explanation of the cause of the message. |
String | Class | Gets the class of the message. |
IDictionary<String, Object> | ExtendedProperties | Gets any additional data items related to the message. |
Int32 | ID | Gets the identification of the message. |
String | Message | Gets the text of the message. |
Int32 | Priority | Defines the property for the message. Conventionally, this property should have a value between 0 and 99. |
String | Recovery | Gets a suggestion on how to recover from the situation that caused the message to be issued. |
MessageSource | Source | Gets the message source. |
String | SourceAsString | Gets a friendly string of the message source. |
TraceEventType | Type | Gets the type of of message. |
Methods
Signature | Description |
---|---|
FriendlySourceName(MessageSource) | Produces a friendly string for a message source. |
Write() | Adds a the message to the default job logger. |
WriteToLog(IJobLogger) | Adds the message to a logger. |
string FriendlySourceName(MessageSource src)
Produces a friendly string for a message source.
string FriendlySourceName(MessageSource src)
Parameters
Type | Parameter name | Description |
---|---|---|
MessageSource | src | The message source. |
Returns
Type | Description |
---|---|
String | The friendly name. |
void Write()
Adds a the message to the default job logger.
void Write()
void WriteToLog(IJobLogger log)
Adds the message to a logger.
void WriteToLog(IJobLogger log)
Parameters
Type | Parameter name | Description |
---|---|---|
IJobLogger | log | The logger to receive the message. |