From ba63f96a7dd500592aebee6180761e0120274ac6 Mon Sep 17 00:00:00 2001 From: Angelina Velinska Date: Tue, 5 May 2020 13:35:38 +0300 Subject: [PATCH] updated for java11 and clojure 1.10.0 with JAXB Runtime from Glassfish --- project.clj | 6 ++++-- src/clj_docx/core.clj | 4 ++-- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/project.clj b/project.clj index 3566020..2e02055 100644 --- a/project.clj +++ b/project.clj @@ -1,4 +1,6 @@ (defproject clj-docx "0.0.3" :description "Wrapper for docx4j" - :dependencies [[org.clojure/clojure "1.5.1"] - [org.docx4j/docx4j "2.8.1"]]) + :dependencies [[org.clojure/clojure "1.10.0"] + [org.docx4j/docx4j "6.1.2"] + [javax.xml.bind/jaxb-api "2.3.1"] + [org.glassfish.jaxb/jaxb-runtime "2.3.2"]]) diff --git a/src/clj_docx/core.clj b/src/clj_docx/core.clj index 589c8c2..f8df8cf 100644 --- a/src/clj_docx/core.clj +++ b/src/clj_docx/core.clj @@ -5,11 +5,11 @@ (org.docx4j.wml Body P R Br Text STBrType) (org.docx4j XmlUtils)) (:require - [clojure.java.io :refer [input-stream resource]])) + [clojure.java.io :refer [input-stream resource file]])) (defn load-wordml-pkg [filename] "Loads up a WordML Package object from a file" - (WordprocessingMLPackage/load (-> filename resource input-stream))) + (WordprocessingMLPackage/load (file filename))) (defn extract-body-from-pkg "Extracts Body from a WordML Package"