upm: add facility for exception handling in upm

We add a new src/upm_exception.i interface file for SWIG to catch
common exceptions and propagate them through SWIG.

src/upm.i is modified to include this interface file, so all UPM
drivers have it.

In theory, this should be language agnostic - if the target language
supports exceptions, then it should just work.

Signed-off-by: Jon Trulson <jtrulson@ics.com>
Signed-off-by: Mihai Tudor Panu <mihai.tudor.panu@intel.com>
This commit is contained in:
Jon Trulson
2015-08-07 13:27:19 -06:00
committed by Mihai Tudor Panu
parent 58c800e246
commit 84f795e453
2 changed files with 66 additions and 0 deletions

View File

@ -1,5 +1,6 @@
%include "std_string.i"
%include "stdint.i"
%include "upm_exception.i"
%typemap(out) mraa_result_t = int;