diff options
author | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-09-01 09:52:51 +0200 |
---|---|---|
committer | Andreas Fitzek <andreas.fitzek@iaik.tugraz.at> | 2014-09-01 09:52:51 +0200 |
commit | 8fd373b3c463350ba2112963b29901dec0921827 (patch) | |
tree | 75259011223c9ae3874b86cfcc62ab2ed15a8f27 | |
parent | ceb032dc4f3ed09d5883a3759a6c62f5f6510f4a (diff) | |
download | pdf-as-4-8fd373b3c463350ba2112963b29901dec0921827.tar.gz pdf-as-4-8fd373b3c463350ba2112963b29901dec0921827.tar.bz2 pdf-as-4-8fd373b3c463350ba2112963b29901dec0921827.zip |
removed API warnings
-rw-r--r-- | pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java | 9 | ||||
-rw-r--r-- | pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/PDFToImage.java | 1 |
2 files changed, 4 insertions, 6 deletions
diff --git a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java index 8766a5bd..e14b8ca0 100644 --- a/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java +++ b/pdf-as-cli/src/test/java/at/gv/egiz/pdfas/cli/test/SignaturProfileTest.java @@ -30,7 +30,8 @@ import java.util.ArrayList; import java.util.Iterator; import java.util.List; -import sun.misc.IOUtils; +import org.apache.commons.io.IOUtils; + import at.gv.egiz.pdfas.common.settings.ISettings; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSink; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSource; @@ -87,8 +88,7 @@ public class SignaturProfileTest { } } - byte[] input = IOUtils.readFully(new FileInputStream(sourcePDF), - -1, true); + byte[] input = IOUtils.toByteArray(new FileInputStream(sourcePDF)); IPlainSigner signer = new PAdESSignerKeystore(KS_FILE, KS_ALIAS, KS_PASS, KS_KEY_PASS, KS_TYPE); @@ -114,8 +114,7 @@ public class SignaturProfileTest { fos.close(); } - byte[] inputPDFA = IOUtils.readFully(new FileInputStream(sourcePDFA), - -1, true); + byte[] inputPDFA = IOUtils.toByteArray(new FileInputStream(sourcePDFA)); Iterator<String> itPDFAProfiles = signaturePDFAProfiles.iterator(); while (itPDFAProfiles.hasNext()) { diff --git a/pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/PDFToImage.java b/pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/PDFToImage.java index 0708e249..b1a290e4 100644 --- a/pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/PDFToImage.java +++ b/pdf-as-lib/src/test/java/at/gv/egiz/pdfas/lib/test/mains/PDFToImage.java @@ -13,7 +13,6 @@ import java.util.List; import javax.imageio.ImageIO; -import sun.misc.IOUtils; import at.gv.egiz.pdfas.common.settings.ISettings; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSink; import at.gv.egiz.pdfas.lib.api.ByteArrayDataSource; |