OpenWGA 7.11 - TMLScript reference
Object:
Error
Description |
This is the error object that gets thrown in JavaScript on any error occasion and can be retrieved by the catch statement. Error objects in TMLScript mostly resemble normal JavaScript error objects of the JavaScript 1.5 Standard. The methods and properties documented here are features special to TMLScript that differ from the standard. The differences of TMLScript error objects are caused by the fact that TMLScript is mainly dealing with Java APIs under the hood and therefor needs to be able to cope with the possibility of Java exceptions which should be handleable from TMLScript. |
||||||
Retrieval |
By catch blocks as the parameter given in the brackets. For example: catch(e) |
||||||
Allowed in script types |
|
||||||
Properties and methods |
|
||||||
Examples |
A standard error handling scheme in TMLScript. This script manually tests if the error contains a Java exception and logs it to the applog if so:try { A simpler way to deal with the fact that TMLScript errors may contain Java exceptions is using the method this.logException(), which treats exceptions automatically: try { |