Module: Stringprep::Rfc3454

Defined in:
lib/stringprep/rfc3454.rb

Class Method Summary collapse

Class Method Details

.tablesObject

Loads code point tables from data/rfc3454.json, creates it if it does not exist



8
9
10
11
12
13
14
15
16
17
# File 'lib/stringprep/rfc3454.rb', line 8

def self.tables
  tries = READ_RETRIES
  @tables ||= begin
    raw_read_tables
  rescue Errno::ENOENT
    write_tables(parse_rfc_txt)
    retry if (tries -= 1) > 0
    raise
  end
end