Re: catching uncaught exceptions
Re: catching uncaught exceptions
- Subject: Re: catching uncaught exceptions
- From: matt neuburg <email@hidden>
- Date: Tue, 10 Feb 2004 04:48:04 -0800
On 2/9/04 at roughly 11:03 PM, thus spake cricket <email@hidden>:
>
NSExceptionHandler *handler = [NSExceptionHandler
>
defaultExceptionHandler];
>
[handler setExceptionHandlingMask:NSLogAndHandleEveryExceptionMask];
>
[handle setDelegate:self];
>
>
Then, implemented one of the delegate methods:
>
>
- (BOOL)exceptionHandler:(NSExceptionHandler *)sender
>
shouldHandleException:(NSE
>
xception *)exception mask:(unsigned int)aMask {
>
-- Put up your alert if need be
>
-- Then, decide on what to do, perhaps based on aMask
>
}
Brilliant, thank you very much. (This framework needs better documenting.)
m.
--
matt neuburg, phd = email@hidden,
http://www.tidbits.com/matt/
pantes anthropoi tou eidenai oregontai phusei
AppleScript: the Definitive Guide! NOW SHIPPING...! (Finally.)
http://www.amazon.com/exec/obidos/ASIN/0596005571/somethingsbymatt
Subscribe to TidBITS! It's free and smart.
http://www.tidbits.com/
_______________________________________________
cocoa-dev mailing list | email@hidden
Help/Unsubscribe/Archives:
http://www.lists.apple.com/mailman/listinfo/cocoa-dev
Do not post admin requests to the list. They will be ignored.