让Dbus的Java绑定在Android上运行

问题描述:

有没有人成功地在Android上运行dbus的Java绑定?所有迹象表明,dbus已经在Android操作系统中作为一个进程运行,但没有官方接入点通过Java界面。提前致谢!让Dbus的Java绑定在Android上运行

您可以尝试使用freedesktop项目中的dbus-java。我不知道它是否适用于Android。

+0

感谢您的建议!我试过了,但它需要JNI实现Unix套接字才能运行。这需要将C库推到Android上,我不太确定该怎么做。我已经看到推简单的程序是可能的,但我还没有看到推出完整的图书馆。或者,也许我只是没有正确地运行。 – Moki 2009-10-21 18:00:14

+1

您可以使用TCP而不是unix-sockets,然后您需要修改dbus库的纯Java库 – 2009-10-21 19:43:12

+0

。没有任何配置选项可以在没有unix套接字的情况下构建。 – 2011-05-25 22:10:21

你不应该这样做,除非你正在谈论你自己的公交车与你控制的事情交谈。不保证dbus可用。根据Android的邮件列表,it's just an implementation detail that dbus is around at all, it's not guaranteed to be there, and might not be there in the future.