Class: Locale::Tag::Cldr

Class | Locale::Tag::Cldr
In: | lib/locale/tag/cldr.rb
Parent: | Common

Unicode locale identifier class for CLDR-1.6.1. (Unicode Common Locale Data Repository).

### Methods

extensions= new parse

### Included Modules

Util::Memoizable

### Constants

VARIANT | = | "(#{ALPHANUM}{5,8}|#{DIGIT}#{ALPHANUM}{3})"
EXTENSION | = | "#{ALPHANUM}+=[a-z0-9\-]+"
TAG_RE | = | /\A#{LANGUAGE}(?:[-_]#{SCRIPT})? (?:[-_]#{REGION})?((?:[-_]#{VARIANT})* (?:@(#{EXTENSION};?)+)*)\Z/ix

### Attributes

extensions | [R] |

### Public Class methods

new(language, script = nil, region = nil, variants = [], extensions = {})

Create Locale::Tag::Cldr.

variants should be upcase.

parse(tag)

Parse the language tag and return the new Locale::Tag::CLDR.

### Public Instance methods

extensions=(val)

Sets the extensions as an Hash.

[Validate]