From aa3d636260e94d12789b52bea7841e2daab76bb7 Mon Sep 17 00:00:00 2001 From: "Achim D. Brucker" Date: Tue, 6 Mar 2018 07:44:48 +0000 Subject: [PATCH] Removed unused file. --- .../converter/src/dof_latex_converter.scala | 72 ------------------- 1 file changed, 72 deletions(-) delete mode 100644 document-generator/converter/src/dof_latex_converter.scala diff --git a/document-generator/converter/src/dof_latex_converter.scala b/document-generator/converter/src/dof_latex_converter.scala deleted file mode 100644 index cd0750e..0000000 --- a/document-generator/converter/src/dof_latex_converter.scala +++ /dev/null @@ -1,72 +0,0 @@ -/** - * Copyright (c) 2018 The University of Sheffield. All rights reserved. - * 2018 The University of Paris-Sud. All rights reserved. - * - * Redistribution and use in source and binary forms, with or without - * modification, are permitted provided that the following conditions - * are met: - * 1. Redistributions of source code must retain the above copyright - * notice, this list of conditions and the following disclaimer. - * 2. Redistributions in binary form must reproduce the above copyright - * notice, this list of conditions and the following disclaimer in - * the documentation and/or other materials provided with the - * distribution. - * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS - * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT - * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS - * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE - * COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, - * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, - * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; - * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER - * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT - * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN - * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE - * POSSIBILITY OF SUCH DAMAGE. - * - * SPDX-License-Identifier: BSD-2-Clause - */ - -package com.logicalhacking.dof.converter - -import java.io.{BufferedWriter, File, FileWriter} -import IoUtils._ -import scala.util.matching.Regex - -object DofConverter { - def convertTexLine(line:String) = { - // TODO - line - } - - def convertFile(f: File) = { - val texFileName = f.getAbsolutePath() - println("ODF Converger: converting " + texFileName - + " (Not yet fully implemented!)") - f.renameTo(new File(texFileName+".orig")) - - using(io.Source.fromFile(texFileName+".orig")) { - inputFile => - using(new BufferedWriter(new FileWriter(new File(texFileName), true))) { - outputFile => - outputFile.write("% This file was modified by the DOV LaTex converter\n") - for (line <- inputFile.getLines) { - val outputLine = convertTexLine(line) - outputFile.write(outputLine + "\n") - } - } - } - } - - def main(args: Array[String]): Unit = { - val dir = if (args.length == 0) { - "." - } else { - args(0) - } - val texFiles = recursiveListFiles(new File(dir), new Regex("\\.tex$")) - for (file <- texFiles) { - convertFile(file) - } - } -}