@valueerror/ltjs-lang-en 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +232 -0
- package/NOTICE +10 -0
- package/README.md +25 -2
- package/index.js +34 -0
- package/licenses/LGPL-2.1.txt +504 -0
- package/licenses/english-pos-dict.pom.xml +135 -0
- package/licenses/resource_en_12dicts-readme.html +738 -0
- package/licenses/resource_en_agid-readme.txt +340 -0
- package/licenses/resource_en_pos-readme.txt +115 -0
- package/package.json +60 -4
- package/resource-root.js +4 -0
- package/resources/META-INF/org/languagetool/language-module.properties +1 -0
- package/resources/en-chunker.bin +0 -0
- package/resources/en-pos-maxent.bin +0 -0
- package/resources/en-token.bin +0 -0
- package/resources/org/languagetool/resource/en/12dicts-readme.html +738 -0
- package/resources/org/languagetool/resource/en/added.txt +446 -0
- package/resources/org/languagetool/resource/en/added_custom.txt +4 -0
- package/resources/org/languagetool/resource/en/agid-readme.txt +340 -0
- package/resources/org/languagetool/resource/en/compounds.txt +9059 -0
- package/resources/org/languagetool/resource/en/confusion_sets.txt +871 -0
- package/resources/org/languagetool/resource/en/disambiguation.xml +17238 -0
- package/resources/org/languagetool/resource/en/do-not-synthesize.txt +13 -0
- package/resources/org/languagetool/resource/en/en-US-GB.txt +4804 -0
- package/resources/org/languagetool/resource/en/en.sor +211 -0
- package/resources/org/languagetool/resource/en/english.dict +0 -0
- package/resources/org/languagetool/resource/en/english.info +8 -0
- package/resources/org/languagetool/resource/en/english_synth.dict +0 -0
- package/resources/org/languagetool/resource/en/english_synth.info +7 -0
- package/resources/org/languagetool/resource/en/english_tags.txt +88 -0
- package/resources/org/languagetool/resource/en/hunspell/en_AU.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_AU.info +16 -0
- package/resources/org/languagetool/resource/en/hunspell/en_CA.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_CA.info +13 -0
- package/resources/org/languagetool/resource/en/hunspell/en_GB.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_GB.info +15 -0
- package/resources/org/languagetool/resource/en/hunspell/en_NZ.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_NZ.info +18 -0
- package/resources/org/languagetool/resource/en/hunspell/en_US.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_US.info +15 -0
- package/resources/org/languagetool/resource/en/hunspell/en_ZA.dict +0 -0
- package/resources/org/languagetool/resource/en/hunspell/en_ZA.info +16 -0
- package/resources/org/languagetool/resource/en/hunspell/ignore.txt +11070 -0
- package/resources/org/languagetool/resource/en/hunspell/prohibit.txt +383 -0
- package/resources/org/languagetool/resource/en/hunspell/prohibit_custom.txt +1 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling.txt +477 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_custom.txt +1 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-AU.txt +34 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-CA.txt +28 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-GB.txt +44 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-NZ.txt +31 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-US.txt +41 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_en-ZA.txt +32 -0
- package/resources/org/languagetool/resource/en/hunspell/spelling_merged.txt +0 -0
- package/resources/org/languagetool/resource/en/multiwords.txt +8210 -0
- package/resources/org/languagetool/resource/en/pos-readme.txt +115 -0
- package/resources/org/languagetool/resource/en/removed.txt +31 -0
- package/resources/org/languagetool/resource/en/removed_custom.txt +4 -0
- package/resources/org/languagetool/resource/en/specific_case.txt +5621 -0
- package/resources/org/languagetool/resource/en/word_definitions.txt +1510 -0
- package/resources/org/languagetool/rules/en/coherency.txt +2501 -0
- package/resources/org/languagetool/rules/en/contractions.txt +198 -0
- package/resources/org/languagetool/rules/en/det_a.txt +959 -0
- package/resources/org/languagetool/rules/en/det_an.txt +4080 -0
- package/resources/org/languagetool/rules/en/diacritics.txt +1415 -0
- package/resources/org/languagetool/rules/en/en-AU/grammar.xml +171 -0
- package/resources/org/languagetool/rules/en/en-CA/grammar.xml +197 -0
- package/resources/org/languagetool/rules/en/en-GB/grammar.xml +555 -0
- package/resources/org/languagetool/rules/en/en-GB/replace.txt +104 -0
- package/resources/org/languagetool/rules/en/en-GB/style.xml +302 -0
- package/resources/org/languagetool/rules/en/en-NZ/grammar.xml +171 -0
- package/resources/org/languagetool/rules/en/en-NZ/replace.txt +5 -0
- package/resources/org/languagetool/rules/en/en-US/grammar.xml +913 -0
- package/resources/org/languagetool/rules/en/en-US/replace.txt +74 -0
- package/resources/org/languagetool/rules/en/en-US/style.xml +524 -0
- package/resources/org/languagetool/rules/en/grammar-l2-de.xml +227 -0
- package/resources/org/languagetool/rules/en/grammar-l2-fr.xml +39 -0
- package/resources/org/languagetool/rules/en/grammar.xml +142537 -0
- package/resources/org/languagetool/rules/en/redundancies.txt +866 -0
- package/resources/org/languagetool/rules/en/remote-rule-filters.xml +3622 -0
- package/resources/org/languagetool/rules/en/replace.txt +221 -0
- package/resources/org/languagetool/rules/en/replace_custom.txt +7 -0
- package/resources/org/languagetool/rules/en/replace_profanity.txt +540 -0
- package/resources/org/languagetool/rules/en/style.xml +12556 -0
- package/resources/org/languagetool/rules/en/synonyms.txt +42 -0
- package/resources/org/languagetool/rules/en/wordiness.txt +1061 -0
- package/resources/org/languagetool/rules/en/wrongWordInContext.txt +14 -0
- package/src/lang/en/chunking/EnglishChunkFilter.js +108 -0
- package/src/lang/en/chunking/EnglishChunker.js +135 -0
- package/src/lang/en/language/AmericanEnglish.js +73 -0
- package/src/lang/en/language/AustralianEnglish.js +42 -0
- package/src/lang/en/language/BritishEnglish.js +91 -0
- package/src/lang/en/language/CanadianEnglish.js +70 -0
- package/src/lang/en/language/English.js +398 -0
- package/src/lang/en/language/NewZealandEnglish.js +44 -0
- package/src/lang/en/language/SouthAfricanEnglish.js +40 -0
- package/src/lang/en/language/id2prioBritishEnglish.js +6 -0
- package/src/lang/en/language/id2prioEnglish.js +333 -0
- package/src/lang/en/rules/AbstractEnglishSpellerRule.js +677 -0
- package/src/lang/en/rules/AbstractEnglishSpellerRuleData.js +778 -0
- package/src/lang/en/rules/AdvancedSynthesizerFilter.js +12 -0
- package/src/lang/en/rules/AdverbFilter.js +538 -0
- package/src/lang/en/rules/AmericanReplaceRule.js +57 -0
- package/src/lang/en/rules/AvsAnData.js +37 -0
- package/src/lang/en/rules/AvsAnRule.js +182 -0
- package/src/lang/en/rules/BritishReplaceRule.js +57 -0
- package/src/lang/en/rules/CompoundRule.js +150 -0
- package/src/lang/en/rules/ConsistentApostrophesRule.js +87 -0
- package/src/lang/en/rules/ContractionSpellingRule.js +64 -0
- package/src/lang/en/rules/DateCheckFilter.js +58 -0
- package/src/lang/en/rules/DateFilterHelper.js +51 -0
- package/src/lang/en/rules/EnglishConvertToSentenceCaseFilter.js +17 -0
- package/src/lang/en/rules/EnglishDashRule.js +42 -0
- package/src/lang/en/rules/EnglishDiacriticsRule.js +67 -0
- package/src/lang/en/rules/EnglishMultitokenSpeller.js +15 -0
- package/src/lang/en/rules/EnglishNumberInWordFilter.js +38 -0
- package/src/lang/en/rules/EnglishPartialPosTagFilter.js +29 -0
- package/src/lang/en/rules/EnglishPlainEnglishRule.js +67 -0
- package/src/lang/en/rules/EnglishRedundancyRule.js +67 -0
- package/src/lang/en/rules/EnglishRepeatedWordsRule.js +212 -0
- package/src/lang/en/rules/EnglishSpecificCaseRule.js +47 -0
- package/src/lang/en/rules/EnglishSuppressMisspelledSuggestionsFilter.js +12 -0
- package/src/lang/en/rules/EnglishUnpairedBracketsRule.js +25 -0
- package/src/lang/en/rules/EnglishUnpairedQuotesRule.js +41 -0
- package/src/lang/en/rules/EnglishWordRepeatBeginningRule.js +107 -0
- package/src/lang/en/rules/EnglishWordRepeatRule.js +126 -0
- package/src/lang/en/rules/EnglishWrongWordInContextRule.js +50 -0
- package/src/lang/en/rules/FindSuggestionsFilter.js +41 -0
- package/src/lang/en/rules/FutureDateFilter.js +25 -0
- package/src/lang/en/rules/LongSentenceRule.js +19 -0
- package/src/lang/en/rules/MorfologikAmericanSpellerRule.js +69 -0
- package/src/lang/en/rules/MorfologikAustralianSpellerRule.js +45 -0
- package/src/lang/en/rules/MorfologikBritishSpellerRule.js +47 -0
- package/src/lang/en/rules/MorfologikCanadianSpellerRule.js +45 -0
- package/src/lang/en/rules/MorfologikNewZealandSpellerRule.js +45 -0
- package/src/lang/en/rules/MorfologikSouthAfricanSpellerRule.js +45 -0
- package/src/lang/en/rules/NewYearDateFilter.js +25 -0
- package/src/lang/en/rules/NewZealandReplaceRule.js +56 -0
- package/src/lang/en/rules/NoDisambiguationEnglishPartialPosTagFilter.js +24 -0
- package/src/lang/en/rules/OrdinalSuffixFilter.js +33 -0
- package/src/lang/en/rules/SimpleReplaceProfanityRule.js +55 -0
- package/src/lang/en/rules/SimpleReplaceRule.js +46 -0
- package/src/lang/en/rules/StyleTooOftenUsedAdjectiveRule.js +58 -0
- package/src/lang/en/rules/StyleTooOftenUsedNounRule.js +58 -0
- package/src/lang/en/rules/StyleTooOftenUsedVerbRule.js +58 -0
- package/src/lang/en/rules/UnitConversionRule.js +47 -0
- package/src/lang/en/rules/UnitConversionRuleImperial.js +57 -0
- package/src/lang/en/rules/UnitConversionRuleUS.js +62 -0
- package/src/lang/en/rules/VariantInfo.js +23 -0
- package/src/lang/en/rules/WordCoherencyRule.js +40 -0
- package/src/lang/en/rules/YMDDateCheckFilter.js +25 -0
- package/src/lang/en/rules/YMDNewYearDateFilter.js +25 -0
- package/src/lang/en/rules/translation/BeoLingusTranslator.js +357 -0
- package/src/lang/en/rules/translation/Inflector.js +72 -0
- package/src/lang/en/synthesis/EnglishSynthesizer.js +109 -0
- package/src/lang/en/tagging/EnglishHybridDisambiguator.js +28 -0
- package/src/lang/en/tagging/EnglishTagger.js +78 -0
- package/src/lang/en/tokenizers/EnglishWordTokenizer.js +113 -0
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// org.languagetool.rules.en.AdvancedSynthesizerFilter
|
|
2
|
+
import { registerClass } from '@valueerror/ltjs-core/src/core/resources/ClassBroker.js';
|
|
3
|
+
import { AbstractAdvancedSynthesizerFilter } from '@valueerror/ltjs-core/src/core/rules/AbstractAdvancedSynthesizerFilter.js';
|
|
4
|
+
|
|
5
|
+
// Java: AdvancedSynthesizerFilter
|
|
6
|
+
export class AdvancedSynthesizerFilter extends AbstractAdvancedSynthesizerFilter {
|
|
7
|
+
static FQCN = 'org.languagetool.rules.en.AdvancedSynthesizerFilter';
|
|
8
|
+
static JAVA_ABSTRACT = false;
|
|
9
|
+
static JAVA_CONSTRUCTORS = [{ params: [], text: 'public org.languagetool.rules.en.AdvancedSynthesizerFilter()' }];
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
registerClass(AdvancedSynthesizerFilter.FQCN, AdvancedSynthesizerFilter);
|
|
@@ -0,0 +1,538 @@
|
|
|
1
|
+
// org.languagetool.rules.en.AdverbFilter
|
|
2
|
+
import { registerClass } from '@valueerror/ltjs-core/src/core/resources/ClassBroker.js';
|
|
3
|
+
import { RuleFilter } from '@valueerror/ltjs-core/src/core/patterns/RuleFilter.js';
|
|
4
|
+
|
|
5
|
+
// Java: AdverbFilter (static table copied entry by entry; later duplicate keys win like HashMap#put)
|
|
6
|
+
export class AdverbFilter extends RuleFilter {
|
|
7
|
+
static FQCN = 'org.languagetool.rules.en.AdverbFilter';
|
|
8
|
+
static JAVA_ABSTRACT = false;
|
|
9
|
+
static JAVA_CONSTRUCTORS = [{ params: [], text: 'public org.languagetool.rules.en.AdverbFilter()' }];
|
|
10
|
+
|
|
11
|
+
// Java: AdverbFilter#adverb2Adj (instance field initializer)
|
|
12
|
+
adverb2Adj = new Map([
|
|
13
|
+
// irregular ones:
|
|
14
|
+
['well', 'good'],
|
|
15
|
+
['fast', 'fast'],
|
|
16
|
+
['hard', 'hard'],
|
|
17
|
+
['late', 'late'],
|
|
18
|
+
['early', 'early'],
|
|
19
|
+
['daily', 'daily'],
|
|
20
|
+
['straight', 'straight'],
|
|
21
|
+
// regular ones:
|
|
22
|
+
['simply', 'simple'],
|
|
23
|
+
['cheaply', 'cheap'],
|
|
24
|
+
['quickly', 'quick'],
|
|
25
|
+
['slowly', 'slow'],
|
|
26
|
+
['easily', 'easy'],
|
|
27
|
+
['angrily', 'angry'],
|
|
28
|
+
['happily', 'happy'],
|
|
29
|
+
['luckily', 'lucky'],
|
|
30
|
+
['terribly', 'terrible'],
|
|
31
|
+
['tragically', 'tragic'],
|
|
32
|
+
['economically', 'economic'],
|
|
33
|
+
['greatly', 'great'],
|
|
34
|
+
['highly', 'high'],
|
|
35
|
+
['generally', 'general'],
|
|
36
|
+
['differently', 'different'],
|
|
37
|
+
['rightly', 'right'],
|
|
38
|
+
['largely', 'large'],
|
|
39
|
+
['really', 'real'],
|
|
40
|
+
['philosophically', 'philosophical'],
|
|
41
|
+
['directly', 'direct'],
|
|
42
|
+
['clearly', 'clear'],
|
|
43
|
+
['merely', 'mere'],
|
|
44
|
+
['exactly', 'exact'],
|
|
45
|
+
['recently', 'recent'],
|
|
46
|
+
['rapidly', 'rapid'],
|
|
47
|
+
['suddenly', 'sudden'],
|
|
48
|
+
['extremely', 'extreme'],
|
|
49
|
+
['properly', 'proper'],
|
|
50
|
+
['politically', 'political'],
|
|
51
|
+
['probably', 'probable'],
|
|
52
|
+
['self-consciously', 'self-conscious'],
|
|
53
|
+
['successfully', 'successful'],
|
|
54
|
+
['unusually', 'unusual'],
|
|
55
|
+
['obviously', 'obvious'],
|
|
56
|
+
['currently', 'current'],
|
|
57
|
+
['residentially', 'residential'],
|
|
58
|
+
['fully', 'full'],
|
|
59
|
+
['accidentally', 'accidental'],
|
|
60
|
+
['medicinally', 'medicinal'],
|
|
61
|
+
['automatically', 'automatic'],
|
|
62
|
+
['completely', 'complete'],
|
|
63
|
+
['chronologically', 'chronological'],
|
|
64
|
+
['accurately', 'accurate'],
|
|
65
|
+
['necessarily', 'necessary'],
|
|
66
|
+
['temporarily', 'temporary'],
|
|
67
|
+
['significantly', 'significant'],
|
|
68
|
+
['hastily', 'hasty'],
|
|
69
|
+
['immediately', 'immediate'],
|
|
70
|
+
['rarely', 'rare'],
|
|
71
|
+
['totally', 'total'],
|
|
72
|
+
['literally', 'literal'],
|
|
73
|
+
['gently', 'gentle'],
|
|
74
|
+
['finally', 'final'],
|
|
75
|
+
['increasingly', 'increasing'],
|
|
76
|
+
['decreasingly', 'decreasing'],
|
|
77
|
+
['considerably', 'considerable'],
|
|
78
|
+
['effectively', 'effective'],
|
|
79
|
+
['briefly', 'brief'],
|
|
80
|
+
['exceedingly', 'exceeding'],
|
|
81
|
+
['physically', 'physical'],
|
|
82
|
+
['enthusiastically', 'enthusiastic'],
|
|
83
|
+
['incredibly', 'incredible'],
|
|
84
|
+
['permanently', 'permanent'],
|
|
85
|
+
['entirely', 'entire'],
|
|
86
|
+
['surely', 'sure'],
|
|
87
|
+
['positively', 'positive'],
|
|
88
|
+
['negatively', 'negative'],
|
|
89
|
+
['devastatingly', 'devastating'],
|
|
90
|
+
['relatively', 'relative'],
|
|
91
|
+
['absolutely', 'absolute'],
|
|
92
|
+
['socially', 'social'],
|
|
93
|
+
['industriously', 'industrious'],
|
|
94
|
+
['solely', 'sole'],
|
|
95
|
+
['asynchronously', 'asynchronous'],
|
|
96
|
+
['fortunately', 'fortunate'],
|
|
97
|
+
['unfortunately', 'unfortunate'],
|
|
98
|
+
['ideally', 'ideal'],
|
|
99
|
+
['privately', 'private'],
|
|
100
|
+
['unreasonably', 'unreasonable'],
|
|
101
|
+
['personally', 'personal'],
|
|
102
|
+
['basically', 'basic'],
|
|
103
|
+
['definitely', 'definite'],
|
|
104
|
+
['potentially', 'potential'],
|
|
105
|
+
['manually', 'manual'],
|
|
106
|
+
['continuously', 'continuous'],
|
|
107
|
+
['sadly', 'sad'],
|
|
108
|
+
['eventually', 'eventual'],
|
|
109
|
+
['possibly', 'possible'],
|
|
110
|
+
['visually', 'visual'],
|
|
111
|
+
['predominantly', 'predominant'],
|
|
112
|
+
['predominately', 'predominant'], // special case
|
|
113
|
+
['quietly', 'quiet'],
|
|
114
|
+
['slightly', 'slight'],
|
|
115
|
+
['cleverly', 'clever'],
|
|
116
|
+
['roughly', 'rough'],
|
|
117
|
+
['environmentally', 'environmental'],
|
|
118
|
+
['geographically', 'geographical'],
|
|
119
|
+
['usually', 'usual'],
|
|
120
|
+
['normally', 'normal'],
|
|
121
|
+
['deliciously', 'delicious'],
|
|
122
|
+
['steadily', 'steady'],
|
|
123
|
+
['actively', 'active'],
|
|
124
|
+
['schematically', 'schematic'],
|
|
125
|
+
['mindfully', 'mindful'],
|
|
126
|
+
['statistically', 'statistical'],
|
|
127
|
+
['culturally', 'cultural'],
|
|
128
|
+
['vicariously', 'vicarious'],
|
|
129
|
+
['vividly', 'vivid'],
|
|
130
|
+
['partially', 'partial'],
|
|
131
|
+
// put("unduly", "undue");
|
|
132
|
+
['seriously', 'serious'],
|
|
133
|
+
['non-verbally', 'non-verbal'],
|
|
134
|
+
['nonverbally', 'nonverbal'],
|
|
135
|
+
['verbally', 'verbal'],
|
|
136
|
+
['shortly', 'short'],
|
|
137
|
+
['mildly', 'mild'],
|
|
138
|
+
['secretly', 'secret'],
|
|
139
|
+
['especially', 'especial'],
|
|
140
|
+
['specially', 'special'],
|
|
141
|
+
['previously', 'previous'],
|
|
142
|
+
['whitely', 'white'],
|
|
143
|
+
['traditionally', 'traditional'],
|
|
144
|
+
['individually', 'individual'],
|
|
145
|
+
['carefully', 'careful'],
|
|
146
|
+
['essentially', 'essential'],
|
|
147
|
+
['originally', 'original'],
|
|
148
|
+
['alarmingly', 'alarming'],
|
|
149
|
+
['newly', 'new'],
|
|
150
|
+
['wrongfully', 'wrongful'],
|
|
151
|
+
['structurally', 'structural'],
|
|
152
|
+
['globally', 'global'],
|
|
153
|
+
['pacifically', 'pacific'],
|
|
154
|
+
['seemingly', 'seeming'],
|
|
155
|
+
['seamlessly', 'seamless'],
|
|
156
|
+
['sustainably', 'sustainable'],
|
|
157
|
+
['momentarily', 'momentary'],
|
|
158
|
+
['coldly', 'cold'],
|
|
159
|
+
['densely', 'dense'],
|
|
160
|
+
['grimly', 'grim'],
|
|
161
|
+
['calmly', 'calm'],
|
|
162
|
+
['racially', 'racial'],
|
|
163
|
+
['widely', 'wide'],
|
|
164
|
+
['heavily', 'heavy'],
|
|
165
|
+
['authentically', 'authentic'],
|
|
166
|
+
['honestly', 'honest'],
|
|
167
|
+
['desperately', 'desperate'],
|
|
168
|
+
['immensely', 'immense'],
|
|
169
|
+
['apparently', 'apparent'],
|
|
170
|
+
['straightforwardly', 'straightforward'],
|
|
171
|
+
['anatomically', 'anatomical'],
|
|
172
|
+
['uniquely', 'unique'],
|
|
173
|
+
['systemically', 'systemic'],
|
|
174
|
+
['jokily', 'jokey'],
|
|
175
|
+
['critically', 'critical'],
|
|
176
|
+
['equally', 'equal'],
|
|
177
|
+
['strongly', 'strong'],
|
|
178
|
+
['purposely', 'intentional'],
|
|
179
|
+
['thoroughly', 'thorough'],
|
|
180
|
+
['outwardly', 'outward'],
|
|
181
|
+
['horizontally', 'horizontal'],
|
|
182
|
+
['vertically', 'vertical'],
|
|
183
|
+
['technically', 'technical'],
|
|
184
|
+
['swiftly', 'swift'],
|
|
185
|
+
['accessibly', 'accessible'],
|
|
186
|
+
['occasionally', 'occasional'],
|
|
187
|
+
['specifically', 'specific'],
|
|
188
|
+
['subtly', 'subtle'],
|
|
189
|
+
['actually', 'actual'],
|
|
190
|
+
['particularly', 'particular'],
|
|
191
|
+
['gloomily', 'gloomy'],
|
|
192
|
+
['nicely', 'nice'],
|
|
193
|
+
['progressively', 'progressive'],
|
|
194
|
+
['genuinely', 'genuine'],
|
|
195
|
+
['characteristically', 'characteristic'],
|
|
196
|
+
['deeply', 'deep'],
|
|
197
|
+
['spiritually', 'spiritual'],
|
|
198
|
+
['purely', 'pure'],
|
|
199
|
+
['satisfyingly', 'satisfying'],
|
|
200
|
+
['indolently', 'indolent'],
|
|
201
|
+
['obliquely', 'oblique'],
|
|
202
|
+
['preferably', 'preferable'],
|
|
203
|
+
['oddly', 'odd'],
|
|
204
|
+
['professionally', 'professional'],
|
|
205
|
+
['indispensably', 'indispensable'],
|
|
206
|
+
['dispensably', 'dispensable'],
|
|
207
|
+
['consistently', 'consistent'],
|
|
208
|
+
['truly', 'true'],
|
|
209
|
+
['commonly', 'common'],
|
|
210
|
+
['safely', 'safe'],
|
|
211
|
+
['evolutionarily', 'evolutionary'],
|
|
212
|
+
['internally', 'internal'],
|
|
213
|
+
['magically', 'magical'],
|
|
214
|
+
['annually', 'annual'],
|
|
215
|
+
['brightly', 'bright'],
|
|
216
|
+
['officially', 'official'],
|
|
217
|
+
['inofficially', 'inofficial'],
|
|
218
|
+
['perfectly', 'perfect'],
|
|
219
|
+
['overly', 'over'],
|
|
220
|
+
['tropically', 'tropical'],
|
|
221
|
+
['brilliantly', 'brilliant'],
|
|
222
|
+
['exclusively', 'exclusive'],
|
|
223
|
+
['commercially', 'commercial'],
|
|
224
|
+
['mischievously', 'mischievous'],
|
|
225
|
+
['weirdly', 'weird'],
|
|
226
|
+
['routinely', 'routine'],
|
|
227
|
+
['gruffly', 'gruff'],
|
|
228
|
+
['naturally', 'natural'],
|
|
229
|
+
['lightly', 'light'],
|
|
230
|
+
['haphazardly', 'haphazard'],
|
|
231
|
+
['lovingly', 'loving'],
|
|
232
|
+
['sagely', 'sage'],
|
|
233
|
+
['systematically', 'systematical'],
|
|
234
|
+
['academically', 'academical'],
|
|
235
|
+
['jokingly', 'joking'],
|
|
236
|
+
['primarily', 'primary'],
|
|
237
|
+
['secondarily', 'secondary'],
|
|
238
|
+
['peacefully', 'peaceful'],
|
|
239
|
+
['thankfully', 'thankful'],
|
|
240
|
+
['reliably', 'reliable'],
|
|
241
|
+
['unreliably', 'unreliable'],
|
|
242
|
+
['infinitesimally', 'infinitesimal'],
|
|
243
|
+
['hugely', 'huge'],
|
|
244
|
+
['strictly', 'strict'],
|
|
245
|
+
['morally', 'moral'],
|
|
246
|
+
['involuntarily', 'involuntary'],
|
|
247
|
+
['voluntarily', 'voluntary'],
|
|
248
|
+
['vanishingly', 'vanishing'],
|
|
249
|
+
['typically', 'typical'],
|
|
250
|
+
['playfully', 'playful'],
|
|
251
|
+
['wonderfully', 'wonderful'],
|
|
252
|
+
['roguishly', 'roguish'],
|
|
253
|
+
['emotionally', 'emotional'],
|
|
254
|
+
['efficiently', 'efficient'],
|
|
255
|
+
['unkindly', 'unkind'],
|
|
256
|
+
['mentally', 'mental'],
|
|
257
|
+
['credibly', 'credible'],
|
|
258
|
+
['seductively', 'seductive'],
|
|
259
|
+
['rashly', 'rash'],
|
|
260
|
+
['outwards', 'outward'],
|
|
261
|
+
['periodically', 'periodical'],
|
|
262
|
+
['comparatively', 'comparative'],
|
|
263
|
+
['confidentially', 'confidential'],
|
|
264
|
+
['dominantly', 'dominant'],
|
|
265
|
+
['forcibly', 'forcible'],
|
|
266
|
+
['formerly', 'former'],
|
|
267
|
+
['financially', 'financial'],
|
|
268
|
+
['urgently', 'urgent'],
|
|
269
|
+
['inherently', 'inherent'],
|
|
270
|
+
['historically', 'historical'],
|
|
271
|
+
['tightly', 'tight'],
|
|
272
|
+
['greedily', 'greedy'],
|
|
273
|
+
['fluently', 'fluent'],
|
|
274
|
+
['ordinarily', 'ordinary'],
|
|
275
|
+
['inevitably', 'inevitable'],
|
|
276
|
+
['partly', 'partial'],
|
|
277
|
+
['liquidly', 'liquid'],
|
|
278
|
+
['supremely', 'supreme'],
|
|
279
|
+
['initially', 'initial'],
|
|
280
|
+
['unjustly', 'unjust'],
|
|
281
|
+
['justly', 'just'],
|
|
282
|
+
['plausibly', 'plausible'],
|
|
283
|
+
['amiably', 'amiable'],
|
|
284
|
+
['massively', 'massive'],
|
|
285
|
+
['lowly', 'low'],
|
|
286
|
+
['notoriously', 'notorious'],
|
|
287
|
+
['meaningfully', 'meaningful'],
|
|
288
|
+
['approximately', 'approximate'],
|
|
289
|
+
['extraordinarily', 'extraordinary'],
|
|
290
|
+
['warmly', 'warm'],
|
|
291
|
+
['nearly', 'near'],
|
|
292
|
+
['strategically', 'strategical'],
|
|
293
|
+
['endlessly', 'endless'],
|
|
294
|
+
['virtually', 'virtual'],
|
|
295
|
+
['regularly', 'regular'],
|
|
296
|
+
['deliberately', 'deliberate'],
|
|
297
|
+
['reasonably', 'reasonable'],
|
|
298
|
+
['similarly', 'similar'],
|
|
299
|
+
['flexibly', 'flexible'],
|
|
300
|
+
['softly', 'soft'],
|
|
301
|
+
['responsibly', 'responsible'],
|
|
302
|
+
['irresponsibly', 'irresponsible'],
|
|
303
|
+
['sweetly', 'sweet'],
|
|
304
|
+
['comfortably', 'comfortable'],
|
|
305
|
+
['uncomfortably', 'uncomfortable'],
|
|
306
|
+
['intricately', 'intricate'],
|
|
307
|
+
['unnecessarily', 'unnecessary'],
|
|
308
|
+
['obstinately', 'obstinate'],
|
|
309
|
+
['reportedly', 'reported'],
|
|
310
|
+
['loosely', 'loose'],
|
|
311
|
+
['profusely', 'profuse'],
|
|
312
|
+
['mortally', 'mortal'],
|
|
313
|
+
['dynamically', 'dynamical'],
|
|
314
|
+
['illegally', 'illegal'],
|
|
315
|
+
['legally', 'legal'],
|
|
316
|
+
['undoubtedly', 'undoubted'],
|
|
317
|
+
['humanly', 'human'],
|
|
318
|
+
['likewise', 'similar'], // special case
|
|
319
|
+
['intrinsically', 'intrinsic'],
|
|
320
|
+
['substantially', 'substantial'],
|
|
321
|
+
['suspiciously', 'suspicious'],
|
|
322
|
+
['generationally', 'generational'],
|
|
323
|
+
['loudly', 'loud'],
|
|
324
|
+
['moderately', 'moderate'],
|
|
325
|
+
['gravely', 'grave'],
|
|
326
|
+
['temporally', 'temporal'],
|
|
327
|
+
['digitally', 'digital'],
|
|
328
|
+
['finely', 'fine'],
|
|
329
|
+
['respectfully', 'respectful'],
|
|
330
|
+
['questioningly', 'questioning'],
|
|
331
|
+
['diagonally', 'diagonal'],
|
|
332
|
+
['additionally', 'additional'],
|
|
333
|
+
['sexually', 'sexual'],
|
|
334
|
+
['remarkably', 'remarkable'],
|
|
335
|
+
['acutely', 'acute'],
|
|
336
|
+
['linearly', 'linear'],
|
|
337
|
+
['perfunctorily', 'perfunctory'],
|
|
338
|
+
['unbelievably', 'unbelievable'],
|
|
339
|
+
['merrily', 'merry'],
|
|
340
|
+
['beneath', 'below'], // special case
|
|
341
|
+
['lest', 'least'], // special case
|
|
342
|
+
['either', 'other'], // special case
|
|
343
|
+
['nasally', 'nasal'],
|
|
344
|
+
['concretely', 'concrete'],
|
|
345
|
+
['intuitively', 'intuitive'],
|
|
346
|
+
['please', 'pleasing'],
|
|
347
|
+
['intermediately', 'intermediate'],
|
|
348
|
+
['powerfully', 'powerful'],
|
|
349
|
+
['fairly', 'fair'],
|
|
350
|
+
['wholly', 'whole'],
|
|
351
|
+
['keenly', 'keen'],
|
|
352
|
+
['unconsciously', 'unconscious'],
|
|
353
|
+
['consciously', 'conscious'],
|
|
354
|
+
['humanely', 'humane'],
|
|
355
|
+
['honorably', 'honorable'],
|
|
356
|
+
['rudely', 'rude'],
|
|
357
|
+
['incorrectly', 'incorrect'],
|
|
358
|
+
['correctly', 'correct'],
|
|
359
|
+
['mistakenly', 'mistaken'],
|
|
360
|
+
['wrongly', 'wrong'],
|
|
361
|
+
['morosely', 'morose'],
|
|
362
|
+
['worryingly', 'worrying'],
|
|
363
|
+
['drastically', 'drastical'],
|
|
364
|
+
['willingly', 'willing'],
|
|
365
|
+
['additively', 'additive'],
|
|
366
|
+
['drolly', 'droll'],
|
|
367
|
+
['statically', 'statical'],
|
|
368
|
+
['hopefully', 'hopeful'],
|
|
369
|
+
['untruthfully', 'untruthful'],
|
|
370
|
+
['truthfully', 'truthful'],
|
|
371
|
+
['attractively', 'attractive'],
|
|
372
|
+
['supposedly', 'supposed'],
|
|
373
|
+
['overwhelmingly', 'overwhelming'],
|
|
374
|
+
['imperfectly', 'imperfect'],
|
|
375
|
+
['deftly', 'deft'],
|
|
376
|
+
['wildly', 'wild'],
|
|
377
|
+
['sheepishly', 'sheepish'],
|
|
378
|
+
['hotly', 'hot'],
|
|
379
|
+
['genetically', 'genetic'],
|
|
380
|
+
['inexplicably', 'inexplicable'],
|
|
381
|
+
['explicably', 'explicable'],
|
|
382
|
+
['domestically', 'domestical'],
|
|
383
|
+
['invisibly', 'invisible'],
|
|
384
|
+
['visibly', 'visible'],
|
|
385
|
+
['noteworthily', 'noteworthy'],
|
|
386
|
+
['unexpectably', 'unexpectable'],
|
|
387
|
+
['expectably', 'expectable'],
|
|
388
|
+
['foreseeably', 'foreseeable'],
|
|
389
|
+
['unforeseeably', 'unforeseeable'],
|
|
390
|
+
['distinctly', 'distinct'],
|
|
391
|
+
['unequivocally', 'unequivocal'],
|
|
392
|
+
['signally', 'signal'],
|
|
393
|
+
['medically', 'medical'],
|
|
394
|
+
['certainly', 'certain'],
|
|
395
|
+
['beautifully', 'beautiful'],
|
|
396
|
+
['firmly', 'firm'],
|
|
397
|
+
['electrically', 'electrical'],
|
|
398
|
+
['gradually', 'gradual'],
|
|
399
|
+
['grossly', 'gross'],
|
|
400
|
+
['memorably', 'memorable'],
|
|
401
|
+
['unmemorably', 'unmemorable'],
|
|
402
|
+
['shelly', 'shell'],
|
|
403
|
+
['strangely', 'strange'],
|
|
404
|
+
['unhealthily', 'unhealthy'],
|
|
405
|
+
['healthily', 'healthy'],
|
|
406
|
+
['harshly', 'harsh'],
|
|
407
|
+
['proudly', 'proud'],
|
|
408
|
+
['lately', 'late'],
|
|
409
|
+
['remotely', 'remote'],
|
|
410
|
+
['longly', 'long'],
|
|
411
|
+
['politely', 'polite'],
|
|
412
|
+
['ethically', 'ethical'],
|
|
413
|
+
['noticeably', 'noticeable'],
|
|
414
|
+
['unnoticeably', 'unnoticeable'],
|
|
415
|
+
['consequently', 'consequent'],
|
|
416
|
+
['snugly', 'snug'],
|
|
417
|
+
['mainly', 'main'],
|
|
418
|
+
['popularly', 'popular'],
|
|
419
|
+
['improperly', 'improper'],
|
|
420
|
+
['deliverly', 'delivery'],
|
|
421
|
+
['rushingly', 'rushing'],
|
|
422
|
+
['gravitationally', 'gravitational'],
|
|
423
|
+
['cruelly', 'cruel'],
|
|
424
|
+
['optimally', 'optimal'],
|
|
425
|
+
['fictionally', 'fictional'],
|
|
426
|
+
['manageably', 'manageable'],
|
|
427
|
+
['unmanageably', 'unmanageable'],
|
|
428
|
+
['fashionably', 'fashionable'],
|
|
429
|
+
['secondly', 'second'],
|
|
430
|
+
['thirdly', 'third'],
|
|
431
|
+
['curtly', 'curt'],
|
|
432
|
+
['secretively', 'secretive'],
|
|
433
|
+
['surprisingly', 'surprising'],
|
|
434
|
+
['sociologically', 'sociological'],
|
|
435
|
+
['severely', 'severe'],
|
|
436
|
+
['ruffianly', 'ruffian'],
|
|
437
|
+
['bigly', 'big'],
|
|
438
|
+
['frequently', 'frequent'],
|
|
439
|
+
['irrationally', 'irrational'],
|
|
440
|
+
['rationally', 'rational'],
|
|
441
|
+
['riotously', 'riotous'],
|
|
442
|
+
['excruciatingly', 'excruciating'],
|
|
443
|
+
['intensively', 'intensive'],
|
|
444
|
+
['separately', 'separate'],
|
|
445
|
+
['favorably', 'favorable'],
|
|
446
|
+
['favourably', 'favourable'],
|
|
447
|
+
['unfavorably', 'unfavorable'],
|
|
448
|
+
['unfavourably', 'unfavourable'],
|
|
449
|
+
['fittingly', 'fitting'],
|
|
450
|
+
['orally', 'oral'],
|
|
451
|
+
['jointly', 'joint'],
|
|
452
|
+
['methodically', 'methodical'],
|
|
453
|
+
['ecologically', 'ecological'],
|
|
454
|
+
['irrepressibly', 'irrepressible'],
|
|
455
|
+
['repressibly', 'repressible'],
|
|
456
|
+
['heartily', 'hearty'],
|
|
457
|
+
['smoothly', 'smooth'],
|
|
458
|
+
['dreamily', 'dreamy'],
|
|
459
|
+
['indirectly', 'indirect'],
|
|
460
|
+
['fascinatingly', 'fascinating'],
|
|
461
|
+
['scientifically', 'scientific'],
|
|
462
|
+
['unhappily', 'unhappy'],
|
|
463
|
+
['publicly', 'public'],
|
|
464
|
+
['healthfully', 'healthful'],
|
|
465
|
+
['uncharacteristically', 'uncharacteristic'],
|
|
466
|
+
['genially', 'genial'],
|
|
467
|
+
['ineludibly', 'ineludible'],
|
|
468
|
+
['tenderly', 'tender'],
|
|
469
|
+
['arguably', 'arguable'],
|
|
470
|
+
['comparably', 'comparable'],
|
|
471
|
+
['procedurally', 'procedural'],
|
|
472
|
+
['interchangeably', 'interchangeable'],
|
|
473
|
+
['conceivably', 'conceivable'],
|
|
474
|
+
['jokily', 'joking'],
|
|
475
|
+
['resignedly', 'resigned'],
|
|
476
|
+
['vehemently', 'vehement'],
|
|
477
|
+
['horribly', 'horrible'],
|
|
478
|
+
['teasingly', 'teasing'],
|
|
479
|
+
['figuratively', 'figurative'],
|
|
480
|
+
['excitingly', 'exciting'],
|
|
481
|
+
['haltingly', 'halting'],
|
|
482
|
+
['phonetically', 'phonetic'],
|
|
483
|
+
['proverbially', 'proverbial'],
|
|
484
|
+
['informally', 'informal'],
|
|
485
|
+
['cozily', 'cozy'],
|
|
486
|
+
['cosily', 'cosy'],
|
|
487
|
+
['constantly', 'constant'],
|
|
488
|
+
['rightfully', 'rightful'],
|
|
489
|
+
['reluctantly', 'reluctant'],
|
|
490
|
+
['externally', 'external'],
|
|
491
|
+
['intellectually', 'intellectual'],
|
|
492
|
+
['dramatically', 'dramatic'],
|
|
493
|
+
['freshly', 'fresh'],
|
|
494
|
+
['casually', 'casual'],
|
|
495
|
+
['unevenly', 'uneven'],
|
|
496
|
+
['enormously', 'enormous'],
|
|
497
|
+
['callously', 'callous'],
|
|
498
|
+
['imperiously', 'imperious'],
|
|
499
|
+
['messily', 'messy'],
|
|
500
|
+
['alternatively', 'alternative'],
|
|
501
|
+
['gladly', 'glad'],
|
|
502
|
+
['adversely', 'adverse'],
|
|
503
|
+
['petulantly', 'petulant'],
|
|
504
|
+
['shakily', 'shaky'],
|
|
505
|
+
['menacingly', 'menacing'],
|
|
506
|
+
['consensually', 'consensual'],
|
|
507
|
+
['bitterly', 'bitter'],
|
|
508
|
+
['terminally', 'terminal'],
|
|
509
|
+
['faintly', 'faint'],
|
|
510
|
+
['brusquely', 'brusque'],
|
|
511
|
+
['humbly', 'humble'],
|
|
512
|
+
['promptly', 'prompt'],
|
|
513
|
+
['identically', 'identical'],
|
|
514
|
+
['militarily', 'military'],
|
|
515
|
+
['neatly', 'neat'],
|
|
516
|
+
['insanely', 'insane'],
|
|
517
|
+
['analytically', 'analytical'],
|
|
518
|
+
['firstly', 'first'],
|
|
519
|
+
['secondly', 'second'],
|
|
520
|
+
['twice', 'second'], // special case
|
|
521
|
+
// TODO: add more or maybe use https://github.com/simplenlg/simplenlg?
|
|
522
|
+
//put("", "");
|
|
523
|
+
]);
|
|
524
|
+
|
|
525
|
+
// Java: AdverbFilter#acceptRuleMatch(RuleMatch,Map,int,AnalyzedTokenReadings[],List)
|
|
526
|
+
acceptRuleMatch(match, args) {
|
|
527
|
+
const adverb = args.get('adverb');
|
|
528
|
+
const noun = args.get('noun');
|
|
529
|
+
const adjective = this.adverb2Adj.get(adverb);
|
|
530
|
+
if (adjective !== undefined && adjective !== adverb) {
|
|
531
|
+
// we can't simply cut off "ly" because of cases like "simply" -> "simple" etc.
|
|
532
|
+
match.setSuggestedReplacement(adjective + ' ' + noun);
|
|
533
|
+
}
|
|
534
|
+
return match;
|
|
535
|
+
}
|
|
536
|
+
}
|
|
537
|
+
|
|
538
|
+
registerClass(AdverbFilter.FQCN, AdverbFilter);
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
// org.languagetool.rules.en.AmericanReplaceRule
|
|
2
|
+
import { AbstractSimpleReplaceRule2 } from '@valueerror/ltjs-core/src/core/rules/AbstractSimpleReplaceRule2.js';
|
|
3
|
+
import { Categories } from '@valueerror/ltjs-core/src/core/rules/model/Category.js';
|
|
4
|
+
import { ITSIssueType } from '@valueerror/ltjs-core/src/core/rules/model/ITSIssueType.js';
|
|
5
|
+
import { Example } from '@valueerror/ltjs-core/src/core/rules/model/Examples.js';
|
|
6
|
+
import { Objects } from '@valueerror/ltjs-core/src/lib/java/Objects.js';
|
|
7
|
+
import { Locale } from '@valueerror/ltjs-core/src/lib/java/Locale.js';
|
|
8
|
+
import { AmericanEnglish } from '../language/AmericanEnglish.js';
|
|
9
|
+
|
|
10
|
+
const EN_US_LOCALE = new Locale('en-US');
|
|
11
|
+
|
|
12
|
+
// Java: AmericanReplaceRule
|
|
13
|
+
export class AmericanReplaceRule extends AbstractSimpleReplaceRule2 {
|
|
14
|
+
static FQCN = 'org.languagetool.rules.en.AmericanReplaceRule';
|
|
15
|
+
static AMERICAN_SIMPLE_REPLACE_RULE = 'EN_US_SIMPLE_REPLACE';
|
|
16
|
+
|
|
17
|
+
// Java: AmericanReplaceRule#getFileNames()
|
|
18
|
+
getFileNames() {
|
|
19
|
+
return [this.path];
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
// Java: AmericanReplaceRule(ResourceBundle,String)
|
|
23
|
+
constructor(messages, path) {
|
|
24
|
+
super(messages, AmericanEnglish.getInstance());
|
|
25
|
+
this.path = Objects.requireNonNull(path);
|
|
26
|
+
this.useSubRuleSpecificIds();
|
|
27
|
+
this.setCategory(Categories.STYLE.getCategory(messages));
|
|
28
|
+
this.setLocQualityIssueType(ITSIssueType.LocaleViolation);
|
|
29
|
+
this.addExamplePair(Example.wrong('Are baked <marker>crisps</marker> healthy?'),
|
|
30
|
+
Example.fixed('Are baked <marker>chips</marker> healthy?'));
|
|
31
|
+
}
|
|
32
|
+
|
|
33
|
+
// Java: AmericanReplaceRule#getId()
|
|
34
|
+
getId() {
|
|
35
|
+
return AmericanReplaceRule.AMERICAN_SIMPLE_REPLACE_RULE;
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
// Java: AmericanReplaceRule#getDescription()
|
|
39
|
+
getDescription() {
|
|
40
|
+
return 'British words easily confused in American English: $match';
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
// Java: AmericanReplaceRule#getShort()
|
|
44
|
+
getShort() {
|
|
45
|
+
return 'British word';
|
|
46
|
+
}
|
|
47
|
+
|
|
48
|
+
// Java: AmericanReplaceRule#getMessage()
|
|
49
|
+
getMessage() {
|
|
50
|
+
return "'$match' is a common British expression. Consider using expressions more common to American English.";
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
// Java: AmericanReplaceRule#getLocale()
|
|
54
|
+
getLocale() {
|
|
55
|
+
return EN_US_LOCALE;
|
|
56
|
+
}
|
|
57
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
// org.languagetool.rules.en.AvsAnData
|
|
2
|
+
import { getDataBroker } from '@valueerror/ltjs-core/src/core/resources/LtStatics.js';
|
|
3
|
+
import { decodeUtf8, scannerLines } from '@valueerror/ltjs-core/src/lib/java/io.js';
|
|
4
|
+
import { javaTrim, toLowerCase } from '@valueerror/ltjs-core/src/lib/java/strings.js';
|
|
5
|
+
|
|
6
|
+
let requiresA = null;
|
|
7
|
+
let requiresAn = null;
|
|
8
|
+
|
|
9
|
+
// Java: AvsAnData#getWordsRequiringA() (static final field, initialised on first use)
|
|
10
|
+
export function getWordsRequiringA() {
|
|
11
|
+
if (requiresA === null) requiresA = loadWords('/en/det_a.txt');
|
|
12
|
+
return requiresA;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
// Java: AvsAnData#getWordsRequiringAn() (static final field, initialised on first use)
|
|
16
|
+
export function getWordsRequiringAn() {
|
|
17
|
+
if (requiresAn === null) requiresAn = loadWords('/en/det_an.txt');
|
|
18
|
+
return requiresAn;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
// Java: AvsAnData#loadWords(String) (ObjectOpenHashSet used for lookup only)
|
|
22
|
+
function loadWords(path) {
|
|
23
|
+
const set = new Set();
|
|
24
|
+
const stream = getDataBroker().getFromRulesDirAsStream(path);
|
|
25
|
+
for (const raw of scannerLines(decodeUtf8(stream))) {
|
|
26
|
+
const line = javaTrim(raw);
|
|
27
|
+
if (line.length === 0 || line.charAt(0) === '#') {
|
|
28
|
+
continue;
|
|
29
|
+
}
|
|
30
|
+
if (line.charAt(0) === '*') {
|
|
31
|
+
set.add(line.substring(1));
|
|
32
|
+
} else {
|
|
33
|
+
set.add(toLowerCase(line));
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return set;
|
|
37
|
+
}
|