See Doc/Manual/Java.html, 24.5.7 Java Exceptions from Directors,
for details on usage. Basic functionality allows a director:except
feature to be added to a director method to add a manually written
handler to map java exceptions back to c++ exceptions. Alternatively,
use new "directorthrows" typemaps to automatically generate handler
blocks for methods in a fashion analogous to the "throws" typemap.
Incorporated changes from discussions with W. Fulton - an implicit
default feature defined in java.cxx can be overridden as documented,
with variable replacements for $directorthrowshandlers and
$defaulthandler. Default behavior is same as swig 2.0.x (directors
swallow exceptions thrown from java side) but now generate swig
warning 476 for any known exceptions that are not being handled).
Simplified approach for cases with and without exceptions
specifications, see documentation.
Added correct behavior for director exceptions when %catches feature
is used to define exceptions to be handled.
Add DirectorException based on python DirectorException, holding information
to allow reconstruction of java-exception cause.
Restructure ExceptionMessage holder class, adding JavaString used by
ExceptionMessage and DirectorException.
Refactor substituteClassname, substitutePackagePath to properly handle
different permutations of %nspace and -package when substituting
$packagepath and $packagepath/$javaclassname combinations in typemaps
for director exceptions.
Get rid od $defaulthandler and change default to always throw a
Swig::DirectorException when an unmapped java exception occurs in a
Get rid of extra newline when no directorthrows handlers, extra brackets.
Add/update tests and update documentation.