1
0
mirror of https://github.com/mitb-archive/filebot synced 2024-11-02 08:25:02 -04:00

+ String.asciiQuotes() to normalize wierd quotation marks (e.g. "\u00b4\u2018\u2019\u02bb".asciiQuotes() == "''''")

This commit is contained in:
Reinhard Pointner 2015-06-04 17:21:02 +00:00
parent 8a77762e34
commit 10704bc216

View File

@ -17,8 +17,8 @@ public class Normalization {
private static final Pattern checksum = compile("[\\(\\[]\\p{XDigit}{8}[\\]\\)]");
private static final char[] doubleQuotes = new char[] { '\"', '\u0060', '\u00b4', '\u2018', '\u2019', '\u02bb' };
private static final char[] singleQuotes = new char[] { '\'', '\u201c', '\u201d' };
private static final char[] doubleQuotes = new char[] { '\'', '\u0060', '\u00b4', '\u2018', '\u2019', '\u02bb' };
private static final char[] singleQuotes = new char[] { '\"', '\u201c', '\u201d' };
public static String normalizeQuotationMarks(String name) {
for (char[] cs : new char[][] { doubleQuotes, singleQuotes }) {