]> granicus.if.org Git - libjpeg-turbo/commit
Further exception cleanup
authorDRC <information@libjpeg-turbo.org>
Tue, 21 Jul 2015 14:34:02 +0000 (09:34 -0500)
committerDRC <information@libjpeg-turbo.org>
Mon, 27 Jul 2015 08:40:58 +0000 (03:40 -0500)
commit739edeb8a647d428514da522d730a955ff0c1c5c
treef49a5c3a945a5c386b9ed531adf120049f52ec0b
parent10dc5cfeff8b98e2d5ef5482d37fb11883966eb4
Further exception cleanup
Use a new checked exception type (TJException) when passing through
errors from the underlying C library. This gives the application a
choice of catching all exceptions or just those from TurboJPEG.

Throw IllegalArgumentException at the JNI level when arguments to the
JNI function are incorrect, and when one of the TurboJPEG "utility"
functions returns an error (because, per the C API specification, those
functions will only return an error if one of their arguments is out of
range.)

Remove "throws Exception" from the signature of any methods that no
longer pass through an error from the TurboJPEG C library.

Credit Viktor for the new code

Code formatting tweaks
31 files changed:
ChangeLog.txt
java/CMakeLists.txt
java/Makefile.am
java/TJExample.java
java/doc/allclasses-frame.html
java/doc/allclasses-noframe.html
java/doc/index-all.html
java/doc/org/libjpegturbo/turbojpeg/TJ.html
java/doc/org/libjpegturbo/turbojpeg/TJCompressor.html
java/doc/org/libjpegturbo/turbojpeg/TJCustomFilter.html
java/doc/org/libjpegturbo/turbojpeg/TJDecompressor.html
java/doc/org/libjpegturbo/turbojpeg/TJException.html [new file with mode: 0644]
java/doc/org/libjpegturbo/turbojpeg/TJScalingFactor.html
java/doc/org/libjpegturbo/turbojpeg/TJTransform.html
java/doc/org/libjpegturbo/turbojpeg/TJTransformer.html
java/doc/org/libjpegturbo/turbojpeg/YUVImage.html
java/doc/org/libjpegturbo/turbojpeg/package-frame.html
java/doc/org/libjpegturbo/turbojpeg/package-summary.html
java/doc/org/libjpegturbo/turbojpeg/package-tree.html
java/doc/overview-tree.html
java/doc/serialized-form.html
java/org/libjpegturbo/turbojpeg/TJ.java
java/org/libjpegturbo/turbojpeg/TJCompressor.java
java/org/libjpegturbo/turbojpeg/TJCustomFilter.java
java/org/libjpegturbo/turbojpeg/TJDecompressor.java
java/org/libjpegturbo/turbojpeg/TJException.java [new file with mode: 0644]
java/org/libjpegturbo/turbojpeg/TJScalingFactor.java
java/org/libjpegturbo/turbojpeg/TJTransform.java
java/org/libjpegturbo/turbojpeg/TJTransformer.java
java/org/libjpegturbo/turbojpeg/YUVImage.java
turbojpeg-jni.c