Loading TOC...

console.trace

console.trace(
   $message as xs.anyAtomicType,
   [$valueN as xs.anyAtomicType,...]
) as null

Summary

Logs a message and the JavaScript stack trace to ErrorLog.txt

Parameters
$message If the first argument contains any placeholders, each placeholder is replaced with the converted value from its corresponding argument. Here are the placeholders:
  • %s - String
  • %d - Number (both integer and float)
  • %j - JSON. Replaced with the string '[Circular]' if the argument contains circular references.
  • % - single percent sign ('%'). This does not consume an argument.
$valueN A value.

Example

function a() {
  console.trace("value=%d ", 123);
}
function b() {
  a();
}
function c() {
  b();
}
c();
// Output similar to the following is logged to ErrorLog.txt:
// 2015-07-31 14:39:14.923 Info: App-Services: Trace: value=123
// 2015-07-31 14:39:14.923 Info: App-Services:  at a ([anonymous]:2:11)
// 2015-07-31 14:39:14.923 Info: App-Services:  at b ([anonymous]:7:3)
// 2015-07-31 14:39:14.923 Info: App-Services:  at c ([anonymous]:11:3)
// 2015-07-31 14:39:14.923 Info: App-Services:  at  ([anonymous]:14:1)

Comments

    Powered by MarkLogic Server 7.0-4.1 and rundmc | Terms of Use | Privacy Policy