diff options
Diffstat (limited to 'peripheral/libupm/src/java_exceptions.i')
-rw-r--r-- | peripheral/libupm/src/java_exceptions.i | 21 |
1 files changed, 0 insertions, 21 deletions
diff --git a/peripheral/libupm/src/java_exceptions.i b/peripheral/libupm/src/java_exceptions.i deleted file mode 100644 index 235dbe9..0000000 --- a/peripheral/libupm/src/java_exceptions.i +++ /dev/null @@ -1,21 +0,0 @@ -/* ----------------------------------------------------------------------------- - * java_exceptions.i - * - * SWIG library file providing java-specific exception handling in the upm library - * ----------------------------------------------------------------------------- */ - -/* - * Use this macro for functions that read data from a sensor and throw a - * std::runtime_error in case of a read failure -*/ -%define READDATA_EXCEPTION(function) -%javaexception("java.io.IOException") function { - try { - $action - } catch (std::runtime_error &e) { - jclass clazz = jenv->FindClass("java/io/IOException"); - jenv->ThrowNew(clazz, e.what()); - return $null; - } -} -%enddef |