Displaying 1 result from an estimated 1 matches for "toplevelcallinghandlers".
2009 Apr 14
0
top level condition handlers
...t;- c( "customError", class( err) )
err
}
> withCallingHandlers( { signalCondition(customError( "ouch")) } ,
customError = function(e) cat( "gotcha : ", e$message, "\n" ) )
gotcha : ouch
NULL
I'd like to be able to do something like this:
> topLevelCallingHandlers( customError = function(e) cat( "gotcha : ",
e$message, "\n" ) )
> signalCondition( customError( "ouch") )
and the "customError" condition to be caught by the handler I set up
previously.
I tried modifying withCallingHandlers like this:
topLevelCalli...