Holds static data from the Unicode database

Methods
#
D
F
L
N
Constants
ATTRIBUTES = :codepoints, :composition_exclusion, :composition_map, :boundary, :cp1252
Class Public methods
dirname()

Returns the directory in which the data files are stored

     # File activesupport/lib/active_support/multibyte/unicode.rb, line 366
366:         def self.dirname
367:           File.dirname(__FILE__) + '/../values/'
368:         end
filename()

Returns the filename for the data file for this version

     # File activesupport/lib/active_support/multibyte/unicode.rb, line 371
371:         def self.filename
372:           File.expand_path File.join(dirname, "unicode_tables.dat")
373:         end
new()
     # File activesupport/lib/active_support/multibyte/unicode.rb, line 323
323:         def initialize
324:           @codepoints = Hash.new(Codepoint.new)
325:           @composition_exclusion = []
326:           @composition_map = {}
327:           @boundary = {}
328:           @cp1252 = {}
329:         end
Instance Public methods
===(other)
     # File activesupport/lib/active_support/multibyte/unicode.rb, line 353
353:               def ===(other)
354:                 detect { |i| i === other } ? true : false
355:               end
load()

Loads the Unicode database and returns all the internal objects of UnicodeDatabase.

     # File activesupport/lib/active_support/multibyte/unicode.rb, line 343
343:         def load
344:           begin
345:             @codepoints, @composition_exclusion, @composition_map, @boundary, @cp1252 = File.open(self.class.filename, 'rb') { |f| Marshal.load f.read }
346:           rescue Exception => e
347:               raise IOError.new("Couldn't load the Unicode tables for UTF8Handler (#{e.message}), ActiveSupport::Multibyte is unusable")
348:           end
349: 
350:           # Redefine the === method so we can write shorter rules for grapheme cluster breaks
351:           @boundary.each do |k,_|
352:             @boundary[k].instance_eval do
353:               def ===(other)
354:                 detect { |i| i === other } ? true : false
355:               end
356:             end if @boundary[k].kind_of?(Array)
357:           end
358: 
359:           # define attr_reader methods for the instance variables
360:           class << self
361:             attr_reader(*ATTRIBUTES)
362:           end
363:         end