You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@commons.apache.org by gg...@apache.org on 2023/03/21 18:03:27 UTC
[commons-imaging] 04/04: Normalize NPE messages
This is an automated email from the ASF dual-hosted git repository.
ggregory pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/commons-imaging.git
commit b72e985386ef700e50ec726a132fbb67deb175c1
Author: Gary Gregory <ga...@gmail.com>
AuthorDate: Tue Mar 21 14:03:19 2023 -0400
Normalize NPE messages
---
src/main/java/org/apache/commons/imaging/Imaging.java | 12 ++++++------
1 file changed, 6 insertions(+), 6 deletions(-)
diff --git a/src/main/java/org/apache/commons/imaging/Imaging.java b/src/main/java/org/apache/commons/imaging/Imaging.java
index 1406f07f..b973b0ea 100644
--- a/src/main/java/org/apache/commons/imaging/Imaging.java
+++ b/src/main/java/org/apache/commons/imaging/Imaging.java
@@ -901,18 +901,18 @@ public final class Imaging {
* provide this data.</p>
*
* @param src a valid BufferedImage object
- * @param os the OutputStream to which the output image is to be written
+ * @param outputStream the OutputStream to which the output image is to be written
* @param format the format in which the output image is to be written
* @throws ImageWriteException in the event of a format violation, unsupported image format, etc.
* @throws IOException in the event of an unrecoverable I/O exception.
* @see ImagingConstants
*/
- public static void writeImage(final BufferedImage src, final OutputStream os, final ImageFormat format) throws ImageWriteException, IOException {
- Objects.requireNonNull(src, "src must not be null");
- Objects.requireNonNull(os, "os must not be null");
- Objects.requireNonNull(format, "format must not be null");
+ public static void writeImage(final BufferedImage src, final OutputStream outputStream, final ImageFormat format) throws ImageWriteException, IOException {
+ Objects.requireNonNull(src, "src");
+ Objects.requireNonNull(outputStream, "outputStream");
+ Objects.requireNonNull(format, "format");
final ImageParser<?> imageParser = Util.getImageParser(format);
- imageParser.writeImage(src, os, null);
+ imageParser.writeImage(src, outputStream, null);
}
}