OpenWGA 7.10 - TMLScript reference

Method :

registerDbGlobal(name, ref)

On object Design
Usage Defines a "TMLScript global" variable with a scope limited to the current design

This is a special version of Design.registerGlobal() whose globals are not available to all TMLScript code of the server but only to the code defined in the current design.

Therefor this version of a TMLScript global is suitable to register tools that must be globally available for the current design but are of no use for other applications.

Globals with design scope are completely independent from other applications. Multiple apps may register design scope globals with equal names for their own design that do not interfer each other.

Otherwise these reduced scope globals can be used just like their counterparts with wider scope. See Design.registerGlobal() for details.

Design scope globals take precedence over equally named TMLScript globals of global scope. So if there is a reduced scope global defined for your design it will hide an equally named global of global scope inside this design.

For backward compatibility there still is an equally working global function "registerGlobal()" with db parameter available whose use is discouraged since OpenWGA 5.3.

Parameters name (String):
Name by which the variable will be known. Global names must start with an uppercase letter.

ref (String | Java-Objekt | TMLScript-Objekt):
The object to store inside the variable
Allowed in script types
  • WebTML pages and normal WebTML actions
  • Master actions
  • TMLScript tasks in jobs
  • Content type events