Struct.new(*RFC4646_SUBTAGS)
# File lib/i18n/locale/tag/rfc4646.rb, line 25 25: def parser 26: @@parser ||= Rfc4646::Parser 27: end
# File lib/i18n/locale/tag/rfc4646.rb, line 29 29: def parser=(parser) 30: @@parser = parser 31: end
Parses the given tag and returns a Tag instance if it is valid. Returns false if the given tag is not valid according to RFC 4646.
# File lib/i18n/locale/tag/rfc4646.rb, line 20 20: def tag(tag) 21: matches = parser.match(tag) 22: new(*matches) if matches 23: end
# File lib/i18n/locale/tag/rfc4646.rb, line 48 48: def to_a 49: members.collect { |attr| self.send(attr) } 50: end
Disabled; run with --debug to generate this.
Generated with the Darkfish Rdoc Generator 1.1.6.