I18n::Locale::Tag::Parents

Public Instance Methods

parent() click to toggle source
    # File lib/i18n/locale/tag/parents.rb, line 7
 7:         def parent
 8:           @parent ||= begin
 9:             segs = to_a.compact
10:             segs.length > 1 ? self.class.tag(*segs[0..(segs.length-2)].join('-')) : nil
11:           end
12:         end
parents() click to toggle source
    # File lib/i18n/locale/tag/parents.rb, line 18
18:         def parents
19:           @parents ||= ([parent] + (parent ? parent.parents : [])).compact
20:         end
self_and_parents() click to toggle source
    # File lib/i18n/locale/tag/parents.rb, line 14
14:         def self_and_parents
15:           @self_and_parents ||= [self] + parents
16:         end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.