Issue 143: Testing exceptions (cxx_revision) Source: (, ) Nature: Enhancement Severity: Summary: Summary: In the DII, testing what variety of exception is stored in the Request Pseudo-object requires a sequence of dynamic_cast<> or (_narrow) calls. It would be useful to have a single call. Resolution: closed/resolved Revised Text: Change the signature of CORBA::Exception on page 1-94 as follows: // C++ class Exception { public: virtual ~Exception(); virtual void _raise() const = 0; virtual const char * _name() const; virtual const char * _rep_id() const; }; Add the following text on page 1-109, preceding the para that introduces UserException: The _name() function returns the unqualified name of the exception. The _rep_id() function returns the repository ID of the exception. Actions taken: October 1, 1996: Received issue June 13, 2000: closed issue Discussion: End of Annotations:===== >From jon@sems.com Mon Sep 30 20:19:10 1996 Received: from ns.sems.com by amethyst.omg.org.omg.org (5.4R2.01/1.34) id AA05114; Mon, 30 Sep 1996 20:19:10 -0400 Received: from vaccine-bb.netlabs.com (vaccine-bb.sems.com) by proxy.netlabs.com (4.1/SMI-4.1) id AA03395; Mon, 30 Sep 96 16:11:50 PDT Received: from clamp.netlabs.com by vaccine-bb.netlabs.com (4.1/SMI-4.1) id AA00858; Mon, 30 Sep 96 17:17:33 PDT Received: from clamp by clamp.netlabs.com (SMI-8.6/SMI-SVR4) id RAA23933; Mon, 30 Sep 1996 17:17:31 -0700 Sender: jon@sems.com Message-Id: <32506319.7DDB@sems.com> Date: Mon, 30 Sep 1996 17:17:29 -0700 From: Jonathan Biggar Organization: Seagate Enterprise Management Software X-Mailer: Mozilla 3.0 (X11; I; SunOS 5.5.1 sun4m) Mime-Version: 1.0 To: cxx_revision@omg.org, issues@omg.org Subject: Exception usage issues Content-Type: text/plain; charset=us-ascii 2. When using the DII, any exception result is received through the environment stored in the Request pseudo-object. If my client code wants to test what variety of exception is stored there, I must use a sequence of dynamic_cast<> or (_narrow) calls to test each possible exception. It would be very useful if the CORBA::Exception class had an additional member CORBA::RepositoryId CORBA::Exception::_id(), which returned the RepositoryId of the exception. Date: Sun, 19 Dec 1999 20:34:05 +1000 (EST) From: Michi Henning Reply-To: C++ Revision Task Force To: C++ Revision Task Force Subject: Proposal for 143, 253, 259, 260 Message-ID: Organization: Object Oriented Concepts MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-UIDL: $iPe9\LU!!gAg!!e'Yd9 Change the signature of CORBA::Exception on page 1-94 as follows: // C++ class Exception { public: virtual ~Exception(); virtual void _raise() const = 0; virtual const char * _name() const; virtual const char * _repId() const; }; Add the following text on page 1-109, preceding the para that introduces UserException: The _name() function returns the unqualified name of the exception. The _repId() function returns the repository ID of the exception. Cheers, Michi. -- Michi Henning +61 7 3891 5744 Object Oriented Concepts +61 4 1118 2700 (mobile) Suite 4, 904 Stanley St +61 7 3891 5009 (fax) East Brisbane 4169 michi@ooc.com.au AUSTRALIA http://www.ooc.com.au/staff/michi-henning.html Sender: jon@floorboard.com Message-ID: <385D5C1C.BBC1D3CB@floorboard.com> Date: Sun, 19 Dec 1999 14:28:44 -0800 From: Jonathan Biggar X-Mailer: Mozilla 4.7 [en] (X11; U; SunOS 5.5.1 sun4m) X-Accept-Language: en MIME-Version: 1.0 To: C++ Revision Task Force Subject: Re: Proposal for 143, 253, 259, 260 References: Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset=us-ascii X-UIDL: If)e9~MF!!SG_!!~F%e9 Michi Henning wrote: > > Change the signature of CORBA::Exception on page 1-94 as follows: > > // C++ > class Exception { > public: > virtual ~Exception(); > virtual void _raise() const = 0; > virtual const char * _name() const; > virtual const char * _repId() const; > }; > > Add the following text on page 1-109, preceding the para that > introduces > UserException: > > The _name() function returns the unqualified name of the > exception. > > The _repId() function returns the repository ID of the > exception. Good! -- Jon Biggar Floorboard Software jon@floorboard.com jon@biggar.org X-Sender: vinoski@mail.boston.amer.iona.com X-Mailer: QUALCOMM Windows Eudora Pro Version 4.1 Date: Tue, 04 Jan 2000 15:03:45 -0500 To: C++ Revision Task Force From: Steve Vinoski Subject: Re: Proposal for 143, 253, 259, 260 In-Reply-To: Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" X-UIDL: 5]F!!dJid9UkM!!;Lid9 At 08:34 PM 12/19/99 +1000, Michi Henning wrote: > >Change the signature of CORBA::Exception on page 1-94 as follows: > > // C++ > class Exception { > public: > virtual ~Exception(); > virtual void _raise() const = 0; > virtual const char * _name() const; > virtual const char * _repId() const; > }; > >Add the following text on page 1-109, preceding the para that introduces >UserException: > > The _name() function returns the unqualified name of the exception. > > The _repId() function returns the repository ID of the exception. For consistency with the rest of the specification, I recommend naming the _repId() function as _rep_id(). --steve Date: Wed, 5 Jan 2000 07:18:26 +1000 (EST) From: Michi Henning To: Steve Vinoski cc: C++ Revision Task Force Subject: Re: Proposal for 143, 253, 259, 260 In-Reply-To: <4.1.20000104150252.01eaed80@mail.boston.amer.iona.com> Message-ID: Organization: Object Oriented Concepts MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII X-UIDL: ?A6e9`4n!!oRT!!i@Ud9 On Tue, 4 Jan 2000, Steve Vinoski wrote: > > The _repId() function returns the repository ID of the exception. > > For consistency with the rest of the specification, I recommend naming the > _repId() function as _rep_id(). Oops. Yes, you are right, of course. Thanks for spotting this! Cheers, Michi. -- Michi Henning +61 7 3891 5744 Object Oriented Concepts +61 4 1118 2700 (mobile) Suite 4, 904 Stanley St +61 7 3891 5009 (fax) East Brisbane 4169 michi@ooc.com.au AUSTRALIA http://www.ooc.com.au/staff/michi-henning.html