Holds static data from the Unicode database
Returns the directory in which the data files are stored
# File lib/active_support/multibyte/unicode.rb, line 365 365: def self.dirname 366: File.dirname(__FILE__) + '/../values/' 367: end
# File lib/active_support/multibyte/unicode.rb, line 352 352: def ===(other) 353: detect { |i| i === other } ? true : false 354: end
Loads the Unicode database and returns all the internal objects of UnicodeDatabase.
# File lib/active_support/multibyte/unicode.rb, line 342 342: def load 343: begin 344: @codepoints, @composition_exclusion, @composition_map, @boundary, @cp1252 = File.open(self.class.filename, 'rb') { |f| Marshal.load f.read } 345: rescue Exception => e 346: raise IOError.new("Couldn't load the Unicode tables for UTF8Handler (#{e.message}), ActiveSupport::Multibyte is unusable") 347: end 348: 349: # Redefine the === method so we can write shorter rules for grapheme cluster breaks 350: @boundary.each do |k,_| 351: @boundary[k].instance_eval do 352: def ===(other) 353: detect { |i| i === other } ? true : false 354: end 355: end if @boundary[k].kind_of?(Array) 356: end 357: 358: # define attr_reader methods for the instance variables 359: class << self 360: attr_reader(*ATTRIBUTES) 361: end 362: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.