pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1826442 - /pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java
Date Sun, 11 Mar 2018 13:49:42 GMT
Author: tilman
Date: Sun Mar 11 13:49:42 2018
New Revision: 1826442

URL: http://svn.apache.org/viewvc?rev=1826442&view=rev
Log:
PDFBOX-4071: use base class

Modified:
    pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java

Modified: pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java?rev=1826442&r1=1826441&r2=1826442&view=diff
==============================================================================
--- pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java
(original)
+++ pdfbox/trunk/examples/src/main/java/org/apache/pdfbox/examples/signature/CreateVisibleSignature.java
Sun Mar 11 13:49:42 2018
@@ -20,6 +20,7 @@ import java.io.File;
 import java.io.FileInputStream;
 import java.io.FileOutputStream;
 import java.io.IOException;
+import java.io.InputStream;
 import java.io.RandomAccessFile;
 import java.security.KeyStore;
 import java.security.KeyStoreException;
@@ -83,7 +84,7 @@ public class CreateVisibleSignature exte
      * @throws IOException
      */
     public void setVisibleSignDesigner(String filename, int x, int y, int zoomPercent, 
-            FileInputStream imageStream, int page) 
+            InputStream imageStream, int page) 
             throws IOException
     {
         visibleSignDesigner = new PDVisibleSignDesigner(filename, imageStream, page);
@@ -97,7 +98,7 @@ public class CreateVisibleSignature exte
      * @param imageStream input stream of an image.
      * @throws IOException
      */
-    public void setVisibleSignDesigner(int zoomPercent, FileInputStream imageStream) 
+    public void setVisibleSignDesigner(int zoomPercent, InputStream imageStream) 
             throws IOException
     {
         visibleSignDesigner = new PDVisibleSignDesigner(imageStream);
@@ -415,7 +416,7 @@ public class CreateVisibleSignature exte
 
         File signedDocumentFile;
         int page;
-        try (FileInputStream imageStream = new FileInputStream(args[3]))
+        try (InputStream imageStream = new FileInputStream(args[3]))
         {
             String name = documentFile.getName();
             String substring = name.substring(0, name.lastIndexOf('.'));



Mime
View raw message