Skip to content

Commit c110196

Browse files
authored
CLDR-18843 Remove organization Special (#5116)
1 parent abd6d5e commit c110196

File tree

16 files changed

+40
-168
lines changed

16 files changed

+40
-168
lines changed

tools/cldr-apps/src/main/java/org/unicode/cldr/web/api/OrgList.java

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,9 +59,7 @@ public static final class OrgMapResponse {
5959
() -> {
6060
Map<String, String> map = new TreeMap<>();
6161
for (Organization o : Organization.values()) {
62-
if (o.visibleOnFrontEnd()) {
63-
map.put(o.name(), o.getDisplayName());
64-
}
62+
map.put(o.name(), o.getDisplayName());
6563
}
6664
return map;
6765
});

tools/cldr-code/src/main/java/org/unicode/cldr/test/SubmissionLocales.java

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -37,10 +37,6 @@ public final class SubmissionLocales {
3737
public static final Set<String> CLDR_LOCALES =
3838
StandardCodes.make().getLocaleToLevel(Organization.cldr).keySet();
3939

40-
/** This is the 'special' list from Locales.txt */
41-
public static final Set<String> SPECIAL_ORG_LOCALES =
42-
StandardCodes.make().getLocaleToLevel(Organization.special).keySet();
43-
4440
/**
4541
* Non-CLDR Locales, but consistently have high level of engagement from volunteers to keep at
4642
* modern level. Reevaluate for each release based on meeting 95+% of modern, moderate, and
@@ -49,16 +45,10 @@ public final class SubmissionLocales {
4945
public static Set<String> HIGH_LEVEL_LOCALES =
5046
ImmutableSet.of(
5147
// Note: ALL of these were found in Locales.txt under cldr.
52-
"chr", // Cherokee
5348
"gd", // Scottish Gaelic, Gaelic
54-
"fo", // Faroese
5549
"kok", // Konkani
5650
"pcm", // Nigerian Pidgin
57-
"ha", // Hausa
58-
"hsb", // Upper Sorbian
59-
"dsb", // Lower Sorbian
60-
"yue_Hans", // Cantonese (Simplified)
61-
"to" // Tongan
51+
"ha" // Hausa
6252
);
6353

6454
public static final Set<String> CLDR_OR_HIGH_LEVEL_LOCALES =
@@ -98,7 +88,6 @@ public final class SubmissionLocales {
9888
LOCALES_FOR_LIMITED = ImmutableSortedSet.copyOf(temp);
9989

10090
Set<String> temp2 = new HashSet<>(CLDR_LOCALES);
101-
temp2.removeAll(SPECIAL_ORG_LOCALES);
10291
TC_ORG_LOCALES = ImmutableSortedSet.copyOf(temp2);
10392
}
10493

tools/cldr-code/src/main/java/org/unicode/cldr/tool/ChartLocaleGrowth.java

Lines changed: 16 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,6 @@ public class ChartLocaleGrowth {
5454
testInfo.getSupplementalDataInfo();
5555
static final Set<String> CldrModernLocales =
5656
StandardCodes.make().getLocaleCoverageLocales(Organization.cldr, Set.of(Level.MODERN));
57-
static final Set<String> SpecialLocales =
58-
StandardCodes.make()
59-
.getLocaleCoverageLocales(Organization.special, Set.of(Level.MODERN));
6057

6158
private static org.unicode.cldr.util.Factory factory =
6259
testInfo.getCommonAndSeedAndMainAndAnnotationsFactory();
@@ -371,7 +368,6 @@ private static Map<String, FoundAndTotal> addGrowth(
371368

372369
if (showMissing) {
373370
if (CldrModernLocales.contains(locale)) {
374-
final boolean isSpecial = SpecialLocales.contains(locale);
375371
if (firstShowMissing) {
376372
firstShowMissing = false;
377373
log.printlnWithTabs(
@@ -388,7 +384,7 @@ private static Map<String, FoundAndTotal> addGrowth(
388384
16,
389385
locale
390386
+ "\t"
391-
+ (isSpecial ? "" : "TC")
387+
+ "TC"
392388
+ show(
393389
Level.CORE,
394390
foundCounter,
@@ -414,23 +410,21 @@ private static Map<String, FoundAndTotal> addGrowth(
414410
foundCounter,
415411
unconfirmedCounter,
416412
missingCounter));
417-
if (!isSpecial) {
418-
long count = unconfirmedCounter.getTotal() + missingCounter.getTotal();
419-
for (Entry<MissingStatus, String> statusAndPath : missingPaths.entrySet()) {
420-
logPaths.printlnWithTabs(
421-
3,
422-
locale
423-
+ "\t"
424-
+ count
425-
+ "\t"
426-
+ statusAndPath.getKey()
427-
+ "\t"
428-
+ statusAndPath.getValue());
429-
}
430-
for (String path : unconfirmedPaths) {
431-
logPaths.printlnWithTabs(
432-
3, locale + "\t" + count + "\tunconfirmed\t" + path);
433-
}
413+
long count = unconfirmedCounter.getTotal() + missingCounter.getTotal();
414+
for (Entry<MissingStatus, String> statusAndPath : missingPaths.entrySet()) {
415+
logPaths.printlnWithTabs(
416+
3,
417+
locale
418+
+ "\t"
419+
+ count
420+
+ "\t"
421+
+ statusAndPath.getKey()
422+
+ "\t"
423+
+ statusAndPath.getValue());
424+
}
425+
for (String path : unconfirmedPaths) {
426+
logPaths.printlnWithTabs(
427+
3, locale + "\t" + count + "\tunconfirmed\t" + path);
434428
}
435429
int line = 0;
436430
}

tools/cldr-code/src/main/java/org/unicode/cldr/tool/ListCoverageLevels.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@
88
import com.google.common.collect.ImmutableSortedSet;
99
import com.google.common.collect.Multimap;
1010
import com.google.common.collect.Multiset;
11-
import com.google.common.collect.Sets;
1211
import com.google.common.collect.Streams;
1312
import com.google.common.collect.TreeMultimap;
1413
import com.google.common.collect.TreeMultiset;
@@ -69,10 +68,7 @@ enum Target {
6968

7069
static final StandardCodes stdCodes = StandardCodes.make();
7170

72-
static final Set<String> cldrCoverage =
73-
Sets.difference(
74-
stdCodes.getLocaleCoverageLocales(Organization.cldr),
75-
stdCodes.getLocaleCoverageLocales(Organization.special));
71+
static final Set<String> cldrCoverage = stdCodes.getLocaleCoverageLocales(Organization.cldr);
7672

7773
private static String levelName(Level level) {
7874
return level == Level.COMPREHENSIVE ? "ꞏ" + level : level.toString();

tools/cldr-code/src/main/java/org/unicode/cldr/tool/ShowInconsistentAvailable.java

Lines changed: 2 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@
77
import com.google.common.collect.ImmutableSet;
88
import com.google.common.collect.LinkedHashMultimap;
99
import com.google.common.collect.Multimap;
10-
import com.google.common.collect.Sets;
1110
import com.google.common.collect.TreeMultimap;
1211
import com.ibm.icu.text.DateIntervalInfo;
1312
import com.ibm.icu.text.DateIntervalInfo.PatternInfo;
@@ -86,18 +85,14 @@ private static Set<String> parse(String[] args) {
8685
public static void main(String[] args) {
8786
MyOptions.parse(args);
8887
Set<String> cldrLocales = StandardCodes.make().getLocaleCoverageLocales(Organization.cldr);
89-
Set<String> specialLocales =
90-
StandardCodes.make().getLocaleCoverageLocales(Organization.special);
91-
final Set<String> cldrLocalesWithoutSpecial = Sets.difference(cldrLocales, specialLocales);
92-
9388
if (MyOptions.ordering.option.doesOccur()) {
94-
showOrdering(cldrLocalesWithoutSpecial);
89+
showOrdering(cldrLocales);
9590
}
9691
if (MyOptions.root.option.doesOccur()) {
9792
getRootPaths();
9893
}
9994
if (MyOptions.inconsistencies.option.doesOccur()) {
100-
showInconsistencies(cldrLocalesWithoutSpecial);
95+
showInconsistencies(cldrLocales);
10196
}
10297
}
10398

tools/cldr-code/src/main/java/org/unicode/cldr/tool/ShowLocaleCoverage.java

Lines changed: 6 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -603,7 +603,6 @@ private static void showCoverage(
603603

604604
final Level cldrLocaleLevelGoal =
605605
SC.getLocaleCoverageLevel(Organization.cldr, locale);
606-
final String specialFlag = getSpecialFlag(locale);
607606

608607
final boolean cldrLevelGoalBasicToModern =
609608
Level.CORE_TO_MODERN.contains(cldrLocaleLevelGoal);
@@ -652,8 +651,7 @@ private static void showCoverage(
652651
}
653652
String goalFlag = cldrLocaleLevelGoal == adjustedGoal ? "" : "*";
654653
tsv_missing_counts.println(
655-
specialFlag
656-
+ locale
654+
locale
657655
+ "\t"
658656
+ goalFlag
659657
+ adjustedGoal
@@ -710,7 +708,6 @@ private static void showCoverage(
710708
locale,
711709
language,
712710
script,
713-
specialFlag,
714711
file.getStringValue(path),
715712
goalLevel,
716713
foundLevel,
@@ -730,7 +727,6 @@ private static void showCoverage(
730727
locale,
731728
language,
732729
script,
733-
specialFlag,
734730
file.getStringValue(path),
735731
goalLevel,
736732
foundLevel,
@@ -775,8 +771,7 @@ private static void showCoverage(
775771
.collect(Collectors.joining("; "));
776772

777773
tsv_missing_basic.println(
778-
specialFlag
779-
+ locale //
774+
locale //
780775
+ "\t"
781776
+ statusData.missing //
782777
+ "\t"
@@ -791,8 +786,7 @@ private static void showCoverage(
791786
);
792787
}
793788
tsv_missing_basic.println(
794-
specialFlag
795-
+ locale //
789+
locale //
796790
+ "\t"
797791
+ starredCounter.missingTotal //
798792
+ "\t"
@@ -888,7 +882,7 @@ private static void showCoverage(
888882
final String visibleLevelGoal =
889883
cldrLocaleLevelGoal == Level.UNDETERMINED
890884
? ""
891-
: specialFlag + cldrLocaleLevelGoal.toString();
885+
: cldrLocaleLevelGoal.toString();
892886
final String goalComparedToComputed =
893887
computed == cldrLocaleLevelGoal
894888
? " ≡"
@@ -1060,10 +1054,7 @@ private static void showCoverage(
10601054
+ localeSet.size()
10611055
+ "\t"
10621056
+ Joiner.on(" ")
1063-
.join(
1064-
localeSet.stream()
1065-
.map(x -> x + getSpecialFlag(x))
1066-
.collect(Collectors.toSet()))
1057+
.join(localeSet.stream().collect(Collectors.toSet()))
10671058
+ "\t"
10681059
+ phString);
10691060
}
@@ -1087,12 +1078,6 @@ private static String linkTsv(String tsvFileName, String anchorText) {
10871078
return "<a href='" + TSV_BASE + tsvFileName + "' target='cldr-tsv'>" + anchorText + "</a>";
10881079
}
10891080

1090-
private static String getSpecialFlag(String locale) {
1091-
return SC.getLocaleCoverageLevel(Organization.special, locale) == Level.UNDETERMINED
1092-
? ""
1093-
: "‡";
1094-
}
1095-
10961081
private static class IterableFilter implements Iterable<String> {
10971082
private Iterable<String> source;
10981083

@@ -1153,7 +1138,6 @@ private static String spreadsheetLine(
11531138
String locale,
11541139
String language,
11551140
String script,
1156-
String specialFlag,
11571141
String nativeValue,
11581142
Level cldrLocaleLevelGoal,
11591143
Level itemLevel,
@@ -1185,8 +1169,7 @@ private static String spreadsheetLine(
11851169
}
11861170

11871171
String line =
1188-
specialFlag
1189-
+ language
1172+
language
11901173
+ "\t"
11911174
+ ENGLISH.nameGetter().getNameFromIdentifier(language)
11921175
+ "\t"

tools/cldr-code/src/main/java/org/unicode/cldr/util/CalculateLocaleCoverage.java

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -241,7 +241,6 @@ private void calculateCoverage(final String only) {
241241

242242
final Level cldrLocaleLevelGoal =
243243
SC.getLocaleCoverageLevel(Organization.cldr, locale);
244-
final String specialFlag = getSpecialFlag(locale);
245244

246245
final boolean cldrLevelGoalBasicToModern =
247246
Level.CORE_TO_MODERN.contains(cldrLocaleLevelGoal);
@@ -458,13 +457,6 @@ private void calculateCoverage(final String only) {
458457
(end - start) + " millis = " + ((end - start) / localeCount) + " millis/locale");
459458
}
460459

461-
private static String getSpecialFlag(String locale) {
462-
return StandardCodes.make().getLocaleCoverageLevel(Organization.special, locale)
463-
== Level.UNDETERMINED
464-
? ""
465-
: "‡";
466-
}
467-
468460
private static class IterableFilter implements Iterable<String> {
469461
private Iterable<String> source;
470462

tools/cldr-code/src/main/java/org/unicode/cldr/util/DiffLanguageGroups.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -78,10 +78,7 @@ private LanguageStatus(String s) {
7878
temp.put(x.getKey(), LanguageStatus.OTHER_BASIC_PLUS);
7979
});
8080

81-
Sets.difference(
82-
StandardCodes.make().getLocaleCoverageLocales(Organization.cldr),
83-
StandardCodes.make().getLocaleCoverageLocales(Organization.special))
84-
.stream()
81+
StandardCodes.make().getLocaleCoverageLocales(Organization.cldr).stream()
8582
.forEach(
8683
x -> {
8784
if (!x.contains("_")) temp.put(x, LanguageStatus.TC);

tools/cldr-code/src/main/java/org/unicode/cldr/util/Organization.java

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,6 @@ public enum Organization {
7777
sil("SIL", "SIL International"),
7878
silicon("Stanford SILICON"),
7979
sitelen_pona("Sitelen Pona", "Sitelen Pona Publishers and Typographers Association"),
80-
special("High Coverage and Generated"),
8180
srilanka("Sri Lanka ICTA", "Sri Lanka"),
8281
sunuwar_ws("Sunuwar Sewa Samaj", "Sunuwar Welfare Society"),
8382
surveytool("Survey Tool"),
@@ -179,8 +178,4 @@ public LocaleSet getCoveredLocales() {
179178
}
180179
return localeSet;
181180
}
182-
183-
public boolean visibleOnFrontEnd() {
184-
return this != Organization.special;
185-
}
186181
}

tools/cldr-code/src/main/java/org/unicode/cldr/util/VettingViewer.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1297,8 +1297,6 @@ private void addLocaleStatusColumn(Appendable output, String localeID) throws IO
12971297
private String getLocaleStatusColumn(CLDRLocale locale) {
12981298
if (SpecialLocales.getType(locale) == SpecialLocales.Type.algorithmic) {
12991299
return "AL"; // algorithmic
1300-
} else if (Organization.special.getCoveredLocales().containsLocaleOrParent(locale)) {
1301-
return "HC"; // high coverage
13021300
} else if (Organization.cldr.getCoveredLocales().containsLocaleOrParent(locale)) {
13031301
return "TC"; // Technical Committee
13041302
} else {

0 commit comments

Comments
 (0)