Package com.log4ic.utils.convert.office

Examples of com.log4ic.utils.convert.office.OfficeConverter


    public static File toPDF(File file, String outPath) throws Exception {
        if (officeConverter == null) {
            queueLock.lock();
            if (officeConverter == null) {
                officeConverter = new OfficeConverter();
            }
            queueLock.unlock();
        }
        queueLock.lock();
        runningQueue.add(file);
View Full Code Here


    @Override
    public void run() {
        File in = this.getInFile();
        String out = this.getOutputPath();
        File dir = DocViewerConverter.deploy(in, out);
        OfficeConverter converter = new OfficeConverter();
        try {
            in = converter.toPDF(in, dir.getPath());
            DocViewer.addConvertWorker(new PDFConvertWorker(this.getId(), in, out, splitePage));
        } catch (IOException e) {
            e.printStackTrace();
        } catch (Exception e) {
            e.printStackTrace();
View Full Code Here

    }


    public static void main(String[] args) throws Exception {
        DocViewer.initialize();
        OfficeConverter converter = new OfficeConverter();
        try {
            converter.convert("/home/icode/Desktop/b.txt", "/home/icode/Desktop/b.pdf");
        } catch (IOException e) {
            e.printStackTrace();
        }

        DocViewer.destroy();
View Full Code Here

TOP

Related Classes of com.log4ic.utils.convert.office.OfficeConverter

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.