Sha256: 96151899791b59daa4c1041a873894ac58b402b3ec830804850f4d81a4b174a3

Contents?: true

Size: 813 Bytes

Versions: 5

Compression:

Stored size: 813 Bytes

Contents

# encoding: UTF-8

# Copyright 2012 Twitter, Inc
# http://www.apache.org/licenses/LICENSE-2.0

module TwitterCldr
  module Resources
    module Properties

      class DerivedCorePropertiesImporter < PropertyImporter
        DATA_URL = 'ucd/DerivedCoreProperties.txt'

        def initialize(input_path, database)
          super(
            input_path: input_path,
            property_name: nil,
            data_url: DATA_URL,
            data_path: File.basename(DATA_URL),
            database: database
          )
        end

        private

        def load
          super do |data, ret|
            code_points = expand_range(data[0])
            property_name = format_property_value(data[1])
            ret[property_name][nil] += code_points
          end
        end
      end

    end
  end
end

Version data entries

5 entries across 5 versions & 1 rubygems

Version Path
twitter_cldr-4.0.0 lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb
twitter_cldr-3.6.0 lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb
twitter_cldr-3.5.0 lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb
twitter_cldr-3.4.0 lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb
twitter_cldr-3.3.0 lib/twitter_cldr/resources/properties/derived_core_properties_importer.rb