OScript API/Built-in Package Index

Class: Builder

The functions within the Builder class are intended only for use within the Livelink SDK Builder. They are not available within the Server. In general, these functions are intended to support the Livelink SDK only and are not intended for use by users developing Livelink applications. The interface described below will change without notice.

Class Attributes

Indicates that script execution can be halted with a keyboard sequence (such as CTRL-Break).

Indicates that the Builder should show OScriptVM code.

Indicates that the Builder should show the OScriptVM stack.

Indicates that the Builder will invoke the Debugger when a breakpoint occurs.

Indicates that the Builder will invoke the Debugger when an error occurs during execution.

Indicates that the Builder should save a thread in the Error queue when an error occurs during execution.

Class Methods

Debug( [Dynamic target] )

Invoke the SDK debugger on either a thread or script.

DebugFlags( [Integer flagsMask] )

Controls a variety of internal options within the Livelink SDK environment.

DebuggerOpts( [Integer flagsMask] )

Open and/or bring forward the Debug Window.

EditScript( Object arg1, String arg2 )

Open and/or bring forward the KOSValue window.

Open or bring forward the Thread Window.

TicksPerSlice( [Integer nTicks] )

Class Attributes

Integer CanInterrupt

Indicates that script execution can be halted with a keyboard sequence (such as CTRL-Break). This is a bitmask value to be used in conjunction with Builder.DebugFlags().

Indicates that the Builder should use the new Debugger (the default). This is a bitmask value to be used in conjunction with Builder.DebugFlags().

Indicates that the Builder should show OScriptVM code. This is a bitmask value to be used in conjunction with Builder.DebugFlags().

Indicates that the Builder should show the OScriptVM stack. This is a bitmask value to be used in conjunction with Builder.DebugFlags().

Indicates that the Builder will invoke the Debugger when a breakpoint occurs. This is a constant bitmask value to be used in conjunction with Builder.DebugFlags().

Integer DebugOnError

Indicates that the Builder will invoke the Debugger when an error occurs during execution. This is a constant bitmask value to be used in conjunction with Builder.DebugFlags().

Indicates that the Builder should save a thread in the Error queue when an error occurs during execution. This is a bitmask value to be used in conjunction with Builder.DebugFlags().

Class Methods

Debug

Dynamic Debug( [Dynamic target] )

Invoke the SDK debugger on either a thread or script. Depending upon the value of the target parameter, this function will either target a script or the current thread.

Parameters

target

If the target is a Script, then the script is invoked and placed in the debugger. If no target is specified, then the currently executing script is suspended and placed into the debugger.

Returns:

Undefined

DebugFlags

Integer DebugFlags( [Integer flagsMask] )

Controls a variety of internal options within the Livelink SDK environment. The following constants can be combined with bitwise OR to produce a mask which specifies which options are to be enabled disabled: Builder.CanInterrupt, Builder.DebugOnBreakpoint, and Builder.DebugOnError. When this function is called without arguments, it simply returns the current set of flags.

Parameters

flagsMask

Desired flags combined with bitwise OR.

Returns:

The current value of the DebugFlags. If the flags were changed by this call, then the new value of the flags is returned.

DebuggerOpts

Integer DebuggerOpts( [Integer flagsMask] )

Internal use only. Allows certain debugger features to be disabled. The following constants can be together with bitwise OR to produce a mask which specifies which options are to be enabled or disabled: Builder.DebuggerNewDebugger, Builder.DebuggerShowDsm, and Builder.DebuggerShowStack. When this function is called without arguments, it simply returns the current set of flags.

Parameters

flagsMask

Desired flags combined with bitwise OR.

Returns:

The current value of the DebuggerOpts. If the flags were changed by this call, then the new value of the flags is returned.

DebugWindow

Dynamic DebugWindow()

Open and/or bring forward the Debug Window.

Returns:

Undefined

EditScript

Dynamic EditScript( Object arg1,
                    String arg2 )

Internal use only. Deprecated. Do not use. Unsupported.

Parameters

arg1

Dummy

arg2

Dummy

Returns:

Dummy

OSWindow

Dynamic OSWindow()

Open and/or bring forward the KOSValue window. This window is sometimes useful when trying to discover memory leaks within the application.

Returns:

Undefined

ThreadWindow

Dynamic ThreadWindow()

Open or bring forward the Thread Window. The Thread Window is useful in the event that a script crashes within the Builder without bringing up a Debugger Window.

Returns:

Undefined

TicksPerSlice

Integer TicksPerSlice( [Integer nTicks] )

Internal use only. Examines and/or adjusts the UI responsiveness. The TicksPerSlice value indicates how many VM instructions should be executed before yielding to the user interface layer. A high TicksPerSlice value will mean that background scripts execute rapidly, but that the UI is very unresponsive. Note that this only affects certain scheduled threads within the SDK and does not affect LXE execution, or the execution of a running thread.

Parameters

nTicks

The number of ticks to execute per timeslice.

Returns:

The number of ticks to execute per timeslice.

 Copyright © 2023 OpenText Corporation. All rights reserved.