获取BlackBerry 10日志的最佳方法? [英] The best way to get BlackBerry 10 logs?

查看:53
本文介绍了获取BlackBerry 10日志的最佳方法?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

与iOS和Android相比,BlackBerry 10具有相当复杂的日志系统. 我发现的唯一解决方案是使用javaloader工具,如下所示:

BlackBerry 10 has quite sophisticated logs system compared to iOS and Android. The only solution i found is using javaloader tool like this:

javaloader.exe -u eventlog > eventlog.txt

但是,它似乎仅适用于BlackBerry OS 10之前的版本.我在BlackBerry 10 NDK中找不到此工具.

But it seems to work only with pre-10 versions of BlackBerry OS. I cannot find this tool in BlackBerry 10 NDK.

使用命令行获取日志的最简单方法是什么?

What is the simplest method to get the logs using the command line?

推荐答案

有两种方法,都记录在发行说明.

There are two ways, both documented in the release notes.

如果您可以通过定义以下功能将记录器流(用于应用程序)复制到控制台:

If you can copy the logger stream (for an application) to the console by defining a function like:

void myMessageOutput(QtMsgType type, const char* msg) {
    fprintf(stdout, "%s\n", msg);
    fflush(stdout);
}

然后将其安装为消息处理程序:

Then installing it as a message handler:

int main(int argc, char **argv)
{
    Application app(argc, argv);
    qInstallMsgHandler(myMessageOutput);
    ...
}

您可以使用ssh系统连接到模拟器或设备,并使用slog2info命令.

You can connect to the simulator or device with an ssh system and use the slog2info command.

这篇关于获取BlackBerry 10日志的最佳方法?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆