Class: Conjugators::ActionVerbs::PresentTense
- Inherits:
-
Object
- Object
- Conjugators::ActionVerbs::PresentTense
- Extended by:
- Shared
- Defined in:
- lib/conjugators/action_verbs/present_tense.rb
Constant Summary collapse
- NA =
"N/A".freeze
- OMETV_REGEX =
/^o[mw]etv/.freeze
- ETV_REGEX =
/etv$/.freeze
- S =
?s.freeze
- ETV =
"etv".freeze
- L =
?l.freeze
- M =
?m.freeze
- N =
?n.freeze
- UE_REGEX =
/ue\Z/- UE =
"ue".freeze
- EMPTY_STRING =
"".freeze
- VOWEL_REGEX =
/[aeēiovu]/.freeze
- LGRADES =
{ 'v'.freeze => 'a'.freeze, 'e'.freeze => 'ē'.freeze, }.freeze
- NULL_E_ENDING_REGEX =
/e\z/.freeze
- I_ENDING_REGEX =
/i$/.freeze
- Ē =
'ē'.freeze
- IYĒ =
'iyē'.freeze
- E_SPACE =
'et '.freeze
- SPACE_TOS =
't os'.freeze
Instance Method Summary collapse
- #conjugate! ⇒ Object
-
#initialize(verb) ⇒ PresentTense
constructor
Note, MVSKOKE language here.
- #word_filter ⇒ Object
Methods included from Shared
irregulars_three_way, irregulars_two_way, person_markers
Constructor Details
#initialize(verb) ⇒ PresentTense
Note, MVSKOKE language here
30 31 32 33 34 35 36 37 38 |
# File 'lib/conjugators/action_verbs/present_tense.rb', line 30 def initialize(verb) @verb = verb raise "Invalid verb. Verb must end with 'etv'." unless @verb.end_with?(ETV) raise "Invalid verb. Verb must be at least 5 letters long" unless @verb.size > 4 raise "Invalid verb. Verb must contain at least one vowel (excluding those in the '-etv' suffix)" unless @verb[0..-4].match?(VOWEL_REGEX) @irregular = !!irregulars[@verb] end |
Instance Method Details
#conjugate! ⇒ Object
64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 |
# File 'lib/conjugators/action_verbs/present_tense.rb', line 64 def conjugate! { verb: @verb, first_person_singular: { basic_present: conjugate(tense: :conjugate_1ps, type: :basic_present), basic_durative: conjugate(tense: :conjugate_1ps, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_1ps, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_1ps, type: :ometv_conjugated_auxiliary) }, second_person_singular: { basic_present: conjugate(tense: :conjugate_2ps, type: :basic_present), basic_durative: conjugate(tense: :conjugate_2ps, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_2ps, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_2ps, type: :ometv_conjugated_auxiliary) }, third_person_singular: { basic_present: conjugate(tense: :conjugate_3ps, type: :basic_present), basic_durative: conjugate(tense: :conjugate_3ps, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_3ps, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_3ps, type: :ometv_conjugated_auxiliary) }, first_person_plural: { basic_present: conjugate(tense: :conjugate_1pp, type: :basic_present), basic_durative: conjugate(tense: :conjugate_1pp, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_1pp, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_1pp, type: :ometv_conjugated_auxiliary) }, second_person_plural: { basic_present: conjugate(tense: :conjugate_2pp, type: :basic_present), basic_durative: conjugate(tense: :conjugate_2pp, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_2pp, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_2pp, type: :ometv_conjugated_auxiliary) }, third_person_plural: { basic_present: conjugate(tense: :conjugate_3pp, type: :basic_present), basic_durative: conjugate(tense: :conjugate_3pp, type: :basic_durative), tos_auxiliary: conjugate(tense: :conjugate_3pp, type: :tos_auxiliary), ometv_conjugated_auxiliary: conjugate(tense: :conjugate_3pp, type: :ometv_conjugated_auxiliary) } } end |
#word_filter ⇒ Object
40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 |
# File 'lib/conjugators/action_verbs/present_tense.rb', line 40 def word_filter @@word_filter ||= { "yvfketv" => { :conjugate_1ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_1pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_3pp => { basic_present: [NA], basic_durative: [NA], ometv_conjugated_auxiliary: [NA] }, }, "mometv" => { :conjugate_1ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_1pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, }, "mowetv" => { :conjugate_1ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2ps => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_1pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, :conjugate_2pp => { basic_present: [NA], basic_durative: [NA], tos_auxiliary: [NA], ometv_conjugated_auxiliary: [NA] }, }, } end |