Class: Linguistics::Latin::Verb::ImperativeBlock::ImperativeRuleFactory
- Inherits:
-
Object
- Object
- Linguistics::Latin::Verb::ImperativeBlock::ImperativeRuleFactory
- Defined in:
- lib/latinverb_imperative_block/imperative_rule_factory.rb
Constant Summary collapse
- MAPPING =
{ First: ->(stem, plural_present_imperative){ [stem, stem+"te"] }, Second: ->(stem, plural_present_imperative){ [stem, stem+"te"] }, ThirdIO: ->(stem, plural_present_imperative){ [stem+"e", stem+"ite"] }, Third: ->(stem, plural_present_imperative){ [stem+"e", stem+"ite"] }, Fourth: ->(stem, plural_present_imperative){ [stem+"ī", stem+"īte"] } }
Instance Method Summary collapse
-
#initialize(verb) ⇒ ImperativeRuleFactory
constructor
A new instance of ImperativeRuleFactory.
- #present_tense_rule ⇒ Object
Constructor Details
#initialize(verb) ⇒ ImperativeRuleFactory
Returns a new instance of ImperativeRuleFactory.
15 16 17 |
# File 'lib/latinverb_imperative_block/imperative_rule_factory.rb', line 15 def initialize(verb) @verb = verb end |
Instance Method Details
#present_tense_rule ⇒ Object
19 20 21 |
# File 'lib/latinverb_imperative_block/imperative_rule_factory.rb', line 19 def present_tense_rule MAPPING[type_key] || raise("Could not find mapping for #{type_key}") end |