This is similar to another answer but with additional details that will be useful for momentics users (BlackBerry 10 IDE)
1. Enable the terminal view in the momentics IDE
Window --> Show view --> Other --> Terminal
Select the terminal and press OK
2. Connect to the terminal
Select the Terminal tab (possibly called 'Terminal 1') in your views window.
Select the connect button, it's a green N shaped button on the top right of the top right of the views window.
3. Run the log viewer command
$ slog2info -w
To read more info about this command:
$ slog2info --help
*Note that there shouldn't be any need to provide an ssh user or keys, that is taken care of by the IDE when you use this procedure.
Log statements
You can add logging to your app with the following commands
qDebug() << "This is debug";
qWarning() << "This is a warning";
qCritical() << "This is critical " << somevariable << ", some additional text";
qFatal() << "This is fatal" << somevariable;
-getFile
works faster for me. – Crackleware