gpt4 book ai didi

java - 没有 stub 的 RMI

转载 作者:行者123 更新时间:2023-12-01 11:44:36 25 4
gpt4 key购买 nike

鉴于以下注释:
(找到here)

Note: As of the J2SE 5.0 release, stub classes for remote objects no longer need to be pregenerated using the rmic stub compiler, unless the remote object needs to support clients running in pre-5.0 VMs. If your application needs to support such clients, you will need to generate stub classes for the remote objects used in the application and deploy those stub classes for clients to download. For details on how to generate stub classes, see the tools documentation for rmic [Solaris, Windows]. For details on how to deploy your application along with pregenerated stub classes, see the codebase tutorial.

我的问题很简单:RMI 如何在没有 stub 的情况下工作?

最佳答案

它使用java.lang.reflect.Proxy 动态生成它们。请参阅java.rmi.server.UnicastRemoteObject 的Javadoc 的类序言。

关于java - 没有 stub 的 RMI,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29262404/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com