Namespace webdriver.stacktrace

code »

Classes

webdriver.stacktrace.Frame
Class representing one stack frame.
webdriver.stacktrace.Snapshot
Stores a snapshot of the stack trace at the time this instance was created.
Show:

Global Functions

Formats an error's stack trace.

Parameters
error: !(Error|goog.testing.JsUnitException)
The error to format.
Returns
The formatted error.

Gets the native stack trace if available otherwise follows the call chain. The generated trace will exclude all frames up to and including the call to this function.

Returns
The frames of the stack trace.

Get an error's stack trace with the error string trimmed. V8 prepends the string representation of an error to its stack trace. This function trims the string so that the stack trace can be parsed consistently with the other JS engines.

Parameters
error: (Error|goog.testing.JsUnitException)
The error.
Returns
The stack trace string.

Parses a long firefox stack frame.

Parameters
frameStr: string
The stack frame as string.
Returns
Stack frame object.

Parses one stack frame.

Parameters
frameStr: string
The stack frame as string.
Returns
Stack frame object or null if the parsing failed.

Parses an Error object's stack trace.

Parameters
stack: string
The stack trace.
Returns
Stack frames. The unrecognized frames will be nulled out.

Global Properties

Representation of an anonymous frame in a stack trace generated by goog.testing.stacktrace.

Whether the current browser supports stack traces.

Whether the current environment supports the Error.captureStackTrace function (as of 10/17/2012, only V8).

RegExp pattern for function call in a Chakra (IE) stack trace. This expression creates 2 submatches on the (optional) context and function name, matching identifiers like 'foo.Bar.prototype.baz', 'Anonymous function', 'eval code', and 'Global code'.

Regular expression for parsing on stack frame in Chakra (IE).

Pattern for a function call in a Closure stack trace. Creates three optional submatches: the context, function name, and alias.

Regular expression for parsing a stack frame generated by Closure's goog.testing.stacktrace.

Pattern for a matching the type on a fully-qualified name. Forms an optional sub-match on the type. For example, in "foo.bar.baz", will match on "foo.bar".

RegExp pattern for function call in the Firefox stack trace. Creates a submatch for the function name.

RegExp pattern for function names in the Firefox stack trace. Firefox has extended identifiers to deal with inner functions and anonymous functions: https://bugzilla.mozilla.org/show_bug.cgi?id=433529#c9

Regular expression for parsing one stack frame in Firefox.

RegExp pattern for JavaScript identifiers. We don't support Unicode identifiers defined in ECMAScript v3.

Maximum length of a string that can be matched with a RegExp on Firefox 3x. Exceeding this approximate length will cause string.match to exceed Firefox's stack quota. This situation can be encountered when goog.globalEval is invoked with a long argument; such as when loading a module.

RegExp pattern for an anonymous function call in an Opera stack frame. Creates 2 (optional) submatches: the context object and function name.

RegExp pattern for a function call in an Opera stack frame. Creates 3 (optional) submatches: the function name (if not anonymous), the aliased context object and the function name (if anonymous).

Regular expression for parsing on stack frame in Opera 11.68+

Pattern for matching a fully qualified name. Will create two sub-matches: the type (optional), and the name. For example, in "foo.bar.baz", will match on ["foo.bar", "baz"].

Placeholder for an unparsable frame in a stack trace generated by goog.testing.stacktrace.

RegExp pattern for an URL + position inside the file.

RegExp pattern for function name alias in the V8 stack trace.

RegExp pattern for the context of a function call in V8. Creates two submatches, only one of which will ever match: either the namespace identifier (with optional "new" keyword in the case of a constructor call), or just the "new " phrase for a top level constructor call.

RegExp pattern for function call in the V8 stack trace. Creates 3 submatches with context object (optional), function name and function alias (optional).

RegExp pattern for function names and constructor calls in the V8 stack trace.

RegExp pattern for a location string in a V8 stack frame. Creates two submatches for the location, one for enclosed in parentheticals and on where the location appears alone (which will only occur if the location is the only information in the frame).

Regular expression for parsing one stack frame in V8.