Xentara v2.0.4
User Manual
|
Xentara has a built-in skill named Debugging. This skill provides element that can be used for debugging Xentara systems.
Debugging inspectors are elements that print attributes of other Xentara elements to the standard output.
The following is a possible output for an inspector that prints five noise values generated by a signal generator:
2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 1.value: 0.26521971194059785 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 2.value: 0.714662006106531 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 3.value: 0.8146399618265746 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 4.value: 0.24390532843995444 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 5.value: 0.41490853415830775
The output of an inspector can have an optional title:
Noise Values: ------------- 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 1.value: 0.26521971194059785 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 2.value: 0.714662006106531 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 3.value: 0.8146399618265746 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 4.value: 0.24390532843995444 2021-08-04 13:54:48.000000000 UTC+02:00 - Signal Generator.Noise 5.value: 0.41490853415830775
Debugging inspectors expose a single task named dump. You can insert that task into an execution pipeline and attach it to a timer or an event.
Debugging inspectors have the following members:
key | The inspector’s primary key. |
name | The inspector’s name. The name is the last component of the primary key. |
UUID | The unique UUID of the inspector. |
type | The inspector’s element type. For debugging inspectors, this is always “debugging inspector”. |
category | The inspector’s category. For debugging inspectors, this is always “special purpose”. |
dump | Prints the current values of the attached attributes to the standard output. |
Debugging loggers are elements that allow writing arbitrary text to the standard output.
The following is a possible output for a logger:
2021-09-22 00:24:22.124250000 UTC+02:00: Hello, world!
Loggers can also log warning an error messages:
Noise Values: ------------- 2021-09-22 03:18:22.003070000 UTC+02:00: WARNING: Something annoying just happened 2021-09-22 14:00:57.802440000 UTC+02:00: ERROR: Something went terribly wrong
The log messages can also have an optional caption:
Noise Values: ------------- 2021-09-24 22:09:42.643700000 UTC+02:00 - Pay attention to this: Hello again, world! 2021-09-24 23:44:56.456170000 UTC+02:00 - Pay attention to this: WARNING: Something else annoying just happened 2021-09-25 06:10:08.654970000 UTC+02:00 - Pay attention to this: ERROR: Something went terribly wrong again
Loggers expose three write-only attributes named text, warningText, and errorText. for the three types of messages. You log a text by writing a value to the appropriate attribute.
Debugging Loggers have the following members:
key | The logger’s primary key. |
name | The logger’s name. The name is the last component of the primary key. |
UUID | The unique UUID of the logger. |
type | The logger’s element type. For debugging loggers, this is always “debugging logger”. |
category | The logger’s category. For debugging loggers, this is always “special purpose”. |
text | Write-only attribute that prints the written value to the standard output as a normal message whenever it is written. |
warningText | Write-only attribute that prints the written value to the standard output as a warning message whenever it is written. |
errorText | Write-only attribute that prints the written value to the standard output as an error message whenever it is written. |
To refer to a attribute, use its primary key. The primary key of the text attribute of a logger called “My.Debugging.Logger” is “My.Debugging.Logger.text”.