-
Key: I2JAV12-13
-
Legacy Issue Number: 5468
-
Status: closed
-
Source: International Business Machines ( Ann Collins)
-
Summary:
The IDL to Java spec is very clear about what methods can (and by
implication what methods can't) be used with the singleton ORB and
one of those is create_any(), however it does not mention any
restrictions on the use of Anys obtained in this way. I think this
leads to some inconsistencies and potential problems, for example:1. You cannot use create_output_stream() on the singleton ORB but
you can use create_output_stream() on an Any obtained from the
singleton. Where has this OutputStream come from? Presumably from
the Any's singleton ORB (calling the orb() method on that OutputStream
would return the ORB). At best this seems inconsistent.2. The problem is worse if you now marshal an object reference into
that OutputStream then call create_input_stream() and try to read back
the object reference using a read_Object() call. If the read_Object()
is to return an object reference it needs to have an ORB to associate
it with, but the only ORB available to it is the original Any's
singleton ORB, which cannot support object references. Should this
read_Object() succeed or fail? If it should succeed what ORB should
it be using?There may be similar problems writing and reading other types to these
streams.I feel the spec should state explicitly that operations on an Any
created using the singleton ORB will be limited by the restrictions
applicable to the singleton ORB.I don't think this would affect the intended use of Anys from the
singleton, which is stated as being to describe union labels when
creating a union TypeCode.Proposed resolution:
Add the following sentence to the end of the subsection "Default
initialization" in section 1.21.9.3 ORB Initialization Methods in
the IDL to Java spec:Operations on an Any created using the singleton ORB will be
limited by the restrictions applicable to the singleton ORB;
those which require the use of a fully functional ORB will result
in a NO_IMPLEMENT system exception. -
Reported: I2JAV 1.1 — Tue, 9 Jul 2002 04:00 GMT
-
Disposition: Resolved — I2JAV 1.2
-
Disposition Summary:
resolved
-
Updated: Fri, 6 Mar 2015 20:58 GMT
I2JAV12 — Anys obtained using the singleton ORB
- Key: I2JAV12-13
- OMG Task Force: IDL to Java 2002 RTF