Java 到 AIDL 实用程序

发布于 2024-10-08 05:54:52 字数 98 浏览 0 评论 0原文

我有一个现有的 Java 接口,想通过 AIDL 公开。 有没有办法从Java自动生成AIDL?

我知道 Corba 代码的 Java2IDL,所以这将是 与此类似。

I have an existing Java interface I'd like to expose via AIDL.
Is there a way to auto generate the AIDL from the Java?

I am aware of Java2IDL for Corba code, so this would be something
similar to that.

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(2

我三岁 2024-10-15 05:54:52

我认为这样做很难,因为 Java 和 AIDL 是不同的语言。此外,您可能会通过 AIDL 接口发送和接收用户定义的类型,并且需要在 AIDL 中进行额外的处理。您需要为每个可解析类型创建一个单独的 AIDL 文件。

I think it's hard to do it this way as both Java and AIDL are different languages. Also, it might happen that you are sending and receiving user defined types through AIDL interfaces and that requires additional handling in AIDL. You need to create a separate AIDL file for each parsable type.

墟烟 2024-10-15 05:54:52

据我所知,没有这样的工具。然而,由于 aidl 与 java 接口不同,一些决定应该由程序员做出。这就是为什么这些工具更有可能不会出现。

To my knowledge there is no such tool. However, so as aidl differs from java interfaces some decisions should be made by programmers. That's why it's more likely that these tools will not appear.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文