× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



On Fri, Jun 20, 2008 at 11:10 AM, Christen, Duane J.
<Duane.Christen@xxxxxxxxxxxxx> wrote:
Charles,

It isn't the language, it is the QMHSNDPM API. If I can use it in RPG I can use it in Java. (On the IBM i.)

Basicly, as I understood him, Steve was saying that if you throw an exception over the procedure with the Monitor in it the Monitor won't catch it. I was saying that if you throw an exception over the method with the try/finally in it the try would also not catch it.

I am little more than a java novice, so I don't know if/how java (on another platform) could > throw an exception over its caller. I just knew that on the i you can throw an exception to
any entry on the call stack, and you bypass any exception handlers for the call stack
entries you bypass.

Duane,

in java and C# you simply throw the exception. there is no relative
invocation entry that the exception is thrown to. If the calling
method does not catch the exception, that method is shut down and the
exception is effectively thrown to the next method down the call
stack.

In C#, the try { .... } finally { ... } construct guarantees that the
finally code will always run after the completion of the try code. I
think you code try {... } catch ( ApplicationException excp ) { ... }
finally { ... } to add exception handlers to the mix.

In RPG ILE we can do the same thing with a mix of MONITOR and CEExxxx
invocation exit handlers. It just does not read as well.

-Steve

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.