Functions to configure and use the INVOX Logger. For an overview of how the logging system works, see the Browser Logs section.
Level Value Description FATAL0Critical errors that may cause the application to stop. ERROR1Runtime errors or unexpected conditions. WARN2Potentially harmful situations. INFO3General informational messages. DEBUG4Detailed information for debugging. TRACE5Fine-grained tracing information.
Target Description LOCALSTORAGEStores log messages in the browser's Local Storage (1 MB limit). Sent to the server on login, logout, or when the limit is reached. CONSOLEDisplays log messages in the browser console. Can be combined with other targets. ONLY_SERVERSends each log message directly to the server without storing locally. Takes precedence over LOCALSTORAGE.
Function Description Parameters Returns INVOX.ChangeLogLevel(level) Changes the logger verbosity level. Messages below the set level will be filtered out. LogLevelvoid
INVOX . ChangeLogLevel ( "INFO" ); // Show INFO and above (INFO, WARN, ERROR, FATAL)
INVOX . ChangeLogLevel ( "DEBUG" ); // Show DEBUG and above
Copy to clipboard Function Description Parameters Returns INVOX.ChangeLogTarget(targets) Sets where log messages are sent. Array<LogTarget>void
// Log to browser console only
INVOX . ChangeLogTarget ([ "CONSOLE" ]);
// Log to both Local Storage and browser console
INVOX . ChangeLogTarget ([ "LOCALSTORAGE" , "CONSOLE" ]);
// Send directly to server
INVOX . ChangeLogTarget ([ "ONLY_SERVER" ]);
Copy to clipboard Function Description Parameters Returns INVOX.ChangeLogKeywordsToIgnore(keywords) Sets keywords to filter out from the logs. Messages containing these keywords will not be logged. Array<String>void
INVOX . ChangeLogKeywordsToIgnore ([ "heartbeat" , "keepAlive" ]);
Copy to clipboard Function Description Parameters Returns INVOX.LogTrace(message) Logs a trace-level message. Stringvoid
INVOX . LogTrace ( "Entering function parseResults" );
Copy to clipboard Function Description Parameters Returns INVOX.LogDebug(message) Logs a debug-level message. Stringvoid
INVOX . LogDebug ( "Preparing Direct Dictation session" );
Copy to clipboard Function Description Parameters Returns INVOX.LogInfo(message) Logs an informational message. Stringvoid
INVOX . LogInfo ( "Direct Dictation session connected successfully." );
Copy to clipboard Function Description Parameters Returns INVOX.LogWarn(message) Logs a warning message. Stringvoid
INVOX . LogWarn ( "Direct Dictation connection is recovering." );
Copy to clipboard Function Description Parameters Returns INVOX.LogError(message) Logs an error message. Stringvoid
INVOX . LogError ( "Could not start the Direct Dictation session." );
Copy to clipboard Function Description Parameters Returns INVOX.LogFatal(message) Logs a fatal error message. Stringvoid
INVOX . LogFatal ( "Unrecoverable error occurred." );
Copy to clipboard