Module: TwitterCldr::Resources
- Defined in:
- lib/twitter_cldr/resources.rb,
lib/twitter_cldr/resources/loader.rb,
lib/twitter_cldr/resources/importer.rb,
lib/twitter_cldr/resources/properties.rb,
lib/twitter_cldr/resources/requirements.rb,
lib/twitter_cldr/resources/import_resolver.rb,
lib/twitter_cldr/resources/readme_renderer.rb,
lib/twitter_cldr/resources/aliases_importer.rb,
lib/twitter_cldr/resources/bidi_test_importer.rb,
lib/twitter_cldr/resources/rbnf_test_importer.rb,
lib/twitter_cldr/resources/tailoring_importer.rb,
lib/twitter_cldr/resources/timezones_importer.rb,
lib/twitter_cldr/resources/transforms_importer.rb,
lib/twitter_cldr/resources/unicode_file_parser.rb,
lib/twitter_cldr/resources/hyphenation_importer.rb,
lib/twitter_cldr/resources/regexp_ast_generator.rb,
lib/twitter_cldr/resources/territories_importer.rb,
lib/twitter_cldr/resources/postal_codes_importer.rb,
lib/twitter_cldr/resources/unicode_data_importer.rb,
lib/twitter_cldr/resources/segment_rules_importer.rb,
lib/twitter_cldr/resources/segment_tests_importer.rb,
lib/twitter_cldr/resources/validity_data_importer.rb,
lib/twitter_cldr/resources/language_codes_importer.rb,
lib/twitter_cldr/resources/number_formats_importer.rb,
lib/twitter_cldr/resources/timezone_tests_importer.rb,
lib/twitter_cldr/resources/collation_tests_importer.rb,
lib/twitter_cldr/resources/collation_tries_importer.rb,
lib/twitter_cldr/resources/requirements/pom_manager.rb,
lib/twitter_cldr/resources/transform_tests_importer.rb,
lib/twitter_cldr/resources/currency_symbols_importer.rb,
lib/twitter_cldr/resources/day_period_rules_importer.rb,
lib/twitter_cldr/resources/properties/emoji_importer.rb,
lib/twitter_cldr/resources/timezone_regions_importer.rb,
lib/twitter_cldr/resources/casefolder_class_generator.rb,
lib/twitter_cldr/resources/locales_resources_importer.rb,
lib/twitter_cldr/resources/properties/property_importer.rb,
lib/twitter_cldr/resources/requirements/git_requirement.rb,
lib/twitter_cldr/resources/requirements/icu_requirement.rb,
lib/twitter_cldr/resources/requirements/uca_requirement.rb,
lib/twitter_cldr/resources/properties/prop_list_importer.rb,
lib/twitter_cldr/resources/requirements/cldr_requirement.rb,
lib/twitter_cldr/resources/requirements/emoji_requirement.rb,
lib/twitter_cldr/resources/bcp47_timezone_metadata_importer.rb,
lib/twitter_cldr/resources/properties/age_property_importer.rb,
lib/twitter_cldr/resources/requirements/unicode_requirement.rb,
lib/twitter_cldr/resources/properties/jamo_property_importer.rb,
lib/twitter_cldr/resources/unicode_property_aliases_importer.rb,
lib/twitter_cldr/resources/properties/blocks_property_importer.rb,
lib/twitter_cldr/resources/properties/script_property_importer.rb,
lib/twitter_cldr/resources/requirements/dependency_requirement.rb,
lib/twitter_cldr/resources/properties/line_break_property_importer.rb,
lib/twitter_cldr/resources/properties/word_break_property_importer.rb,
lib/twitter_cldr/resources/properties/bidi_brackets_property_importer.rb,
lib/twitter_cldr/resources/properties/arabic_shaping_property_importer.rb,
lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb,
lib/twitter_cldr/resources/properties/grapheme_break_property_importer.rb,
lib/twitter_cldr/resources/properties/sentence_break_property_importer.rb,
lib/twitter_cldr/resources/properties/unicode_data_properties_importer.rb,
lib/twitter_cldr/resources/properties/east_asian_width_property_importer.rb,
lib/twitter_cldr/resources/properties/script_extensions_property_importer.rb,
lib/twitter_cldr/resources/properties/hangul_syllable_type_property_importer.rb,
lib/twitter_cldr/resources/properties/indic_syllabic_category_property_importer.rb,
lib/twitter_cldr/resources/properties/indic_positional_category_property_importer.rb
Defined Under Namespace
Modules: Properties, Requirements
Classes: AliasesImporter, Bcp47TimezoneMetadataImporter, BidiTestImporter, CasefolderClassGenerator, CollationTestsImporter, CollationTriesImporter, CurrencySymbolsImporter, DayPeriodRulesImporter, HyphenationImporter, ImportResolver, Importer, LanguageCodesImporter, Loader, LocalesResourcesImporter, NumberFormats, NumberFormatsImporter, PostalCodesImporter, RbnfTestImporter, ReadmeAssertionFailure, ReadmeRenderer, RegexpAstGenerator, ResourceLoadError, SegmentRulesImporter, SegmentTestsImporter, TailoringImporter, TerritoriesImporter, TimezoneRegionsImporter, TimezoneTestsImporter, TimezonesImporter, TransformTestsImporter, TransformsImporter, UnicodeDataImporter, UnicodeFileParser, UnicodePropertyAliasesImporter, ValidityDataImporter
Class Method Summary
collapse
Class Method Details
.importer_classes ⇒ Object
102
103
104
105
106
|
# File 'lib/twitter_cldr/resources.rb', line 102
def importer_classes
@importer_classes ||=
standard_importer_classes +
property_importer_classes
end
|
.importer_classes_for_ruby_engine ⇒ Object
108
109
110
111
112
113
114
115
116
117
118
119
|
# File 'lib/twitter_cldr/resources.rb', line 108
def importer_classes_for_ruby_engine
engine = case RUBY_ENGINE
when 'ruby' then :mri
when 'jruby' then :jruby
else
raise "Unsupported RUBY_ENGINE '#{RUBY_ENGINE}'"
end
importer_classes.select do |klass|
klass.default_params[:ruby_engine] == engine
end
end
|
.locale_based_importer_classes_for_ruby_engine ⇒ Object
121
122
123
124
125
|
# File 'lib/twitter_cldr/resources.rb', line 121
def locale_based_importer_classes_for_ruby_engine
importer_classes_for_ruby_engine.select do |klass|
!!klass.default_params[:locales]
end
end
|
.property_importer_classes ⇒ Object
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
|
# File 'lib/twitter_cldr/resources.rb', line 78
def property_importer_classes
@property_importer_classes ||= [
Properties::AgePropertyImporter,
Properties::ArabicShapingPropertyImporter,
Properties::BidiBracketsPropertyImporter,
Properties::BlocksPropertyImporter,
Properties::DerivedCorePropertiesImporter,
Properties::EastAsianWidthPropertyImporter,
Properties::EmojiImporter,
Properties::GraphemeBreakPropertyImporter,
Properties::HangulSyllableTypePropertyImporter,
Properties::IndicPositionalCategoryPropertyImporter,
Properties::IndicSyllabicCategoryPropertyImporter,
Properties::JamoPropertyImporter,
Properties::LineBreakPropertyImporter,
Properties::PropListImporter,
Properties::ScriptExtensionsPropertyImporter,
Properties::ScriptPropertyImporter,
Properties::SentenceBreakPropertyImporter,
Properties::UnicodeDataPropertiesImporter,
Properties::WordBreakPropertyImporter
]
end
|
.standard_importer_classes ⇒ Object
these importer class methods aren’t constants in order to avoid loading all the classes when the library is required
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
|
# File 'lib/twitter_cldr/resources.rb', line 47
def standard_importer_classes
@standard_importer_classes ||= [
AliasesImporter,
Bcp47TimezoneMetadataImporter,
BidiTestImporter,
CasefolderClassGenerator,
CollationTestsImporter,
CollationTriesImporter,
CurrencySymbolsImporter,
DayPeriodRulesImporter,
HyphenationImporter,
LanguageCodesImporter,
LocalesResourcesImporter,
NumberFormatsImporter,
PostalCodesImporter,
RbnfTestImporter,
SegmentRulesImporter,
SegmentTestsImporter,
TailoringImporter,
TerritoriesImporter,
TimezonesImporter,
TimezoneRegionsImporter,
TimezoneTestsImporter,
TransformTestsImporter,
TransformsImporter,
UnicodeDataImporter,
UnicodePropertyAliasesImporter,
ValidityDataImporter,
]
end
|