ICU-1560 add tool hook; we should move all stuff out of this class & into tools except for hook

X-SVN-Rev: 7209
This commit is contained in:
Alan Liu 2001-11-30 05:51:04 +00:00
parent 731c4697bc
commit 28ddb9b532
2 changed files with 16 additions and 2 deletions

View file

@ -61,6 +61,13 @@ public class TransliteratorUtility {
}
}
/**
* Hook to allow tools to access package private method.
*/
public static UnicodeSet getSourceSet(Transliterator t) {
return t.getSourceSet();
}
static void showSourceSet(String ID, Normalizer.Mode m, boolean lowerFirst) throws IOException {
File f = new File("UnicodeSetClosure.txt");
String filename = f.getCanonicalFile().toString();
@ -85,7 +92,7 @@ public class TransliteratorUtility {
}
System.out.println(t.getID() + ": " +
sourceSet.toPattern(true));
out.println("# MINIMAL FILTER GENERATED FOR: " + t.getID() + (forward ? "" : " BACKWARD"));
out.println("# MINIMAL FILTER GENERATED FOR: " + t.getID() + (forward ? "" : " REVERSE"));
out.println(":: "
+ (forward ? "" : "( ")
+ sourceSet.toPattern(true)

View file

@ -61,6 +61,13 @@ public class TransliteratorUtility {
}
}
/**
* Hook to allow tools to access package private method.
*/
public static UnicodeSet getSourceSet(Transliterator t) {
return t.getSourceSet();
}
static void showSourceSet(String ID, Normalizer.Mode m, boolean lowerFirst) throws IOException {
File f = new File("UnicodeSetClosure.txt");
String filename = f.getCanonicalFile().toString();
@ -85,7 +92,7 @@ public class TransliteratorUtility {
}
System.out.println(t.getID() + ": " +
sourceSet.toPattern(true));
out.println("# MINIMAL FILTER GENERATED FOR: " + t.getID() + (forward ? "" : " BACKWARD"));
out.println("# MINIMAL FILTER GENERATED FOR: " + t.getID() + (forward ? "" : " REVERSE"));
out.println(":: "
+ (forward ? "" : "( ")
+ sourceSet.toPattern(true)