Does VisiBroker support the use of Exception as element of sequence?

Does VisiBroker support the use of Exception as element of sequence?

Problem:

  • Product Name:Visibroker
  • Product Version: 521
  • Product Component: ORB
  • Platform/OS Version:ALL

Does VisiBroker support the use of Exception as element of sequence?

Resolution:

In processing sequences - it supports both simple and constructed types, but not exceptions.

test IDL :

 // Example 1: This is a sequence created from a simple data type
 typedef sequence bytestream;


 // Example 2: This is a constructed data type, it can be made into a sequence
 struct MyStruct
 {
 string aField;
 };

 typedef sequence MyStructList;


 // Example 3: This is an exception. It CANNOT be made into a sequence
 exception MyException
 {
 string errMsg;
 };

 typedef sequence MyExceptionList; // This will fail

--------------- IDL complete ------------

The following exception is generated when the IDL is compiled:

idl2java exception.idl
exception.idl: 27:::MyException refers to an exception (expected a type name)


Based on the CORBA specification (3-11) which states,

"An identifier declared to be an exception identifier may thereafter appear only in a raises clause of an operation declaration, and nowhere else."

Hence the standard IDL grammar does not support the use of "Exception" as the element of a sequence. VisiBroker conforms to the specification and does not allow Exceptions as an element of a sequence.

Tags (2)

DISCLAIMER:

Some content on Community Tips & Information pages is not officially supported by Micro Focus. Please refer to our Terms of Use for more detail.
Top Contributors
Version history
Revision #:
1 of 1
Last update:
‎2013-02-15 20:04
Updated by:
 
The opinions expressed above are the personal opinions of the authors, not of Micro Focus. By using this site, you accept the Terms of Use and Rules of Participation. Certain versions of content ("Material") accessible here may contain branding from Hewlett-Packard Company (now HP Inc.) and Hewlett Packard Enterprise Company. As of September 1, 2017, the Material is now offered by Micro Focus, a separately owned and operated company. Any reference to the HP and Hewlett Packard Enterprise/HPE marks is historical in nature, and the HP and Hewlett Packard Enterprise/HPE marks are the property of their respective owners.