Class: ActiveSupport::Inflector::Inflections

Inherits:
Object
  • Object
show all
Defined in:
lib/inflectious/inflector.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#gerundsObject (readonly)

Returns the value of attribute gerunds.



4
5
6
# File 'lib/inflectious/inflector.rb', line 4

def gerunds
  @gerunds
end

Instance Method Details

#stem(rule, replacement) ⇒ Object



10
11
12
13
14
# File 'lib/inflectious/inflector.rb', line 10

def stem(rule, replacement)
  @uncountables.delete(rule) if rule.is_a?(String)
  @uncountables.delete(replacement)
  stems.insert(0, [rule, replacement])
end

#stemsObject



6
7
8
# File 'lib/inflectious/inflector.rb', line 6

def stems
  @stems ||= []
end