W3C home > Mailing lists > Public > public-html-xml@w3.org > October 2011

RE: Suggested revised text for HTML/XML report intro

From: Robert Leif <rleif@rleif.com>
Date: Tue, 4 Oct 2011 06:51:03 -0400
To: "'Larry Masinter'" <masinter@adobe.com>, "'Noah Mendelsohn'" <nrm@arcanedomain.com>, "'John Cowan'" <cowan@mercury.ccil.org>
Cc: "'Anne van Kesteren'" <annevk@opera.com>, <public-html-xml@w3.org>
Message-ID: <024901cc8283$8397ebc0$8ac7c340$@rleif.com>
Larry Masinter, Noah Mendelsohn et al.

One solution to having XHTML forms and similar entities work with XML
data-types is to make a version of the code that employs the CORBA IDL type
Any. This would be a generic or template, which could permit the use of XML
data-Types. I should admit that I have very little knowledge of IDL, except
for its use of in, out, inOut and return. However, I was able to find this
example on the web.

One way to do this is to provide a choice where one of the values is the
collection of standard HTML5 data-types and the other is an instantiated

Bob Leif

11.1 Example using type Any

Before going through this example, you should make sure that you have read
and understood the examples in chapter 2
<http://omniorb.sourceforge.net/omni41/omniORB/omniORB002.html#chap:basic> .
The source code for this example is included in the omniORB distribution, in
the directory src/examples/anyExample. A listing of the source code is
provided at the end of this chapter.

11.1.1 Type Any in IDL

Type Any allows one to delay the decision on the type used in an operation
until run-time. To use type any in IDL, use the keywordany, as in the
following example:

// IDL

interface anyExample {

  any testOp(in any mesg);


The operation testOp()() in this example can now take any value expressible
in OMG IDL as an argument, and can also return any type expressible in OMG

Type Any is mapped into C++ as the type CORBA::Any. When passed as an
argument or as a result of an operation, the following rules apply:






const CORBA::Any& 




Received on Tuesday, 4 October 2011 10:51:45 UTC

This archive was generated by hypermail 2.3.1 : Tuesday, 6 January 2015 19:58:28 UTC