Java 什么是 IOR 文件,它有什么作用,它是如何工作的?
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/1087083/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
What is an IOR file, what does it do, and how does it work?
提问by Thomas Owens
I believe it is related to CORBA in some way (I'm not sure). I'm curious as to its function and how it works. Google isn't helping me when I search for "IOR file", and I'm not sure what else I could search for. Thanks to anyone who can at least point me in the right direction with available resources.
我相信它在某种程度上与 CORBA 相关(我不确定)。我很好奇它的功能以及它是如何工作的。当我搜索“IOR 文件”时,Google 没有帮助我,我不确定我还能搜索什么。感谢任何至少可以使用可用资源为我指明正确方向的人。
采纳答案by tuergeist
An IOR file is a file which contains an Interoperable Object Referencewhich is a kind of a locator string. The IOR file itself contains the IOR. The IOR is an CDR encoded string which, depended on the CORBA version, contains various information regarding the servant who created this string. But basically it works as a locator string.
IOR 文件是包含可互操作对象引用的文件,它是一种定位符字符串。IOR 文件本身包含 IOR。IOR 是 CDR 编码的字符串,取决于 CORBA 版本,它包含有关创建此字符串的仆人的各种信息。但基本上它用作定位符字符串。
Inside the IOR normally an IP, portnumber and object reference of the servant could be found.
在 IOR 中,通常可以找到仆人的 IP、端口号和对象引用。
In a simple hello world example the servant (server) will create this file. The client reads this file and the client ORB (Object Request Broker) will delegate the call from the client to the servant transparently.
在一个简单的 hello world 示例中,仆人(服务器)将创建此文件。客户端读取此文件,客户端 ORB(对象请求代理)将透明地将来自客户端的调用委托给服务方。
All about CORBA: OMG CORBA Websiteor just visit Wikipedia
关于 CORBA:OMG CORBA 网站或访问维基百科
回答by Sébastien Nussbaumer
IOR stands for Interoperable Object Reference and is related to Corba
IOR 代表 Interoperable Object Reference,与 Corba 相关
You can check out "Corba in 5 minutes" here : http://www.pvv.ntnu.no/~ljosa/doc/encycmuclopedia/devenv/corba-index.html
您可以在此处查看“5 分钟内的 Corba”:http: //www.pvv.ntnu.no/~ljosa/doc/encycmuclopedia/devenv/corba-index.html
There's a section explaining what is an IOR
有一节解释了什么是 IOR
回答by Atul Jawale
IOR is a CORBA or RMI-IIOP reference that uniquely identifies an object on a remote CORBA server.
IOR 是唯一标识远程 CORBA 服务器上的对象的 CORBA 或 RMI-IIOP 引用。
IOR can be transmitted in binary over TCP/IP via GIOP-IIOP (encoding may be big-endian or little endian), or serialized into a string of hexadecimal digits (prefixed by string IOR:) to facilitate transport by non-CORBA mechanism such as HTTP, FTP, and email.
IOR 可以通过 GIOP-IIOP 在 TCP/IP 上以二进制形式传输(编码可以是大端或小端),也可以序列化为一串十六进制数字(以字符串 IOR: 为前缀)以促进非 CORBA 机制的传输,例如如 HTTP、FTP 和电子邮件。
To locate a server object at run-time, the client application requires a reference to it. This reference is called an?Interoperable Object Reference?(IOR). An IOR is a text string encoded in a specific way, such that a client ORB can decode the IOR to locate the remote server object. It contains enough information to allow:
要在运行时定位服务器对象,客户端应用程序需要对它的引用。这个引用被称为?Interoperable Object Reference?(IOR)。IOR 是以特定方式编码的文本字符串,以便客户端 ORB 可以解码 IOR 以定位远程服务器对象。它包含足够的信息以允许:
- A request to be directed to the correct server (host, port number)
- An object to be located or created (classname, instance data)
- 请求被定向到正确的服务器(主机、端口号)
- 要定位或创建的对象(类名、实例数据)