[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-libeufin] 21/25: Fix resource loading from JAR.
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-libeufin] 21/25: Fix resource loading from JAR. |
Date: |
Fri, 20 Sep 2019 19:32:59 +0200 |
This is an automated email from the git hooks/post-receive script.
marcello pushed a commit to branch master
in repository libeufin.
commit 3c513525298b7269890c43dcf30a7e7d88ce4c26
Author: Marcello Stanisci <address@hidden>
AuthorDate: Wed Sep 18 23:31:29 2019 +0200
Fix resource loading from JAR.
---
src/main/java/tech/libeufin/XMLManagement.java | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
diff --git a/src/main/java/tech/libeufin/XMLManagement.java
b/src/main/java/tech/libeufin/XMLManagement.java
index 1bccda7..664e0d6 100644
--- a/src/main/java/tech/libeufin/XMLManagement.java
+++ b/src/main/java/tech/libeufin/XMLManagement.java
@@ -38,9 +38,8 @@ public class XMLManagement {
*/
public XMLManagement(){
ClassLoader classLoader = this.getClass().getClassLoader();
-
- File ebics_hev_file = new
File(classLoader.getResource("ebics_hev.xsd").getFile());
- Source schemas[] = {new StreamSource(ebics_hev_file)
+ InputStream ebics_hev_path =
classLoader.getResourceAsStream("ebics_hev.xsd");
+ Source schemas[] = {new StreamSource(ebics_hev_path)
// other StreamSources for other schemas here ..
};
@@ -49,7 +48,7 @@ public class XMLManagement {
this.bundle = sf.newSchema(schemas);
this.validator = this.bundle.newValidator();
} catch (SAXException e) {
- System.out.println("SAX exception shall never happen here " + "("
+ e + ")");
+ e.printStackTrace();
}
}
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [GNUnet-SVN] [taler-libeufin] 12/25: Local test of XML validation., (continued)
- [GNUnet-SVN] [taler-libeufin] 12/25: Local test of XML validation., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 11/25: import sample hev, gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 14/25: Test with XML imported from string., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 13/25: fix test, gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 15/25: Abstracting string conversion to "stream"., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 16/25: Introducing the converters:, gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 20/25: Server responds with ebicsHEVResponse., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 18/25: method to get (XML) strings from JAXB objects., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 23/25: Translating getLogger() into Kotlin., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 19/25: Importing JAXB scaffolding to reflect ebics "hev" types., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 21/25: Fix resource loading from JAR.,
gnunet <=
- [GNUnet-SVN] [taler-libeufin] 25/25: Finish translating Java into Kotlin., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 17/25: Check if the message can be handled by the server., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 24/25: Move XMLManagement.java to Kotlin., gnunet, 2019/09/20
- [GNUnet-SVN] [taler-libeufin] 22/25: Complete initial setup (#5888)., gnunet, 2019/09/20