llt-constants 0.0.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +7 -0
- data/.gitignore +17 -0
- data/.rspec +2 -0
- data/.travis.yml +6 -0
- data/Gemfile +5 -0
- data/LICENSE.txt +22 -0
- data/README.md +52 -0
- data/Rakefile +8 -0
- data/lib/llt/constants.rb +13 -0
- data/lib/llt/constants/abbreviations.rb +13 -0
- data/lib/llt/constants/cardinals.rb +45 -0
- data/lib/llt/constants/conjunctions.rb +27 -0
- data/lib/llt/constants/endings.rb +338 -0
- data/lib/llt/constants/markers.rb +28 -0
- data/lib/llt/constants/numerals.rb +19 -0
- data/lib/llt/constants/particles.rb +18 -0
- data/lib/llt/constants/personal_pronouns.rb +46 -0
- data/lib/llt/constants/phonology.rb +34 -0
- data/lib/llt/constants/prepositions.rb +48 -0
- data/lib/llt/constants/regexps.rb +151 -0
- data/lib/llt/constants/subjunctions.rb +32 -0
- data/lib/llt/constants/verb_endings.rb +148 -0
- data/lib/llt/constants/verb_markers.rb +75 -0
- data/lib/llt/constants/version.rb +5 -0
- data/llt-constants.gemspec +26 -0
- data/spec/lib/llt/constants/endings_spec.rb +23 -0
- data/spec/lib/llt/constants/regexps_spec.rb +372 -0
- data/spec/spec_helper.rb +21 -0
- metadata +147 -0
@@ -0,0 +1,28 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
module Markers
|
4
|
+
class Adjective
|
5
|
+
COMP_MF = "ior"
|
6
|
+
COMP_N = "ius"
|
7
|
+
|
8
|
+
RIM = "rim"
|
9
|
+
LIM = "lim"
|
10
|
+
ISSIM = "issim"
|
11
|
+
|
12
|
+
class Metrical < Adjective
|
13
|
+
# are they right?
|
14
|
+
COMP_MF = "īōr"
|
15
|
+
COMP_N = "īūs"
|
16
|
+
|
17
|
+
RIM = "rīm"
|
18
|
+
LIM = "līm"
|
19
|
+
ISSIM = "īssīm"
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
23
|
+
class Adverb < Adjective
|
24
|
+
IUS = "ius"
|
25
|
+
end
|
26
|
+
end
|
27
|
+
end
|
28
|
+
end
|
@@ -0,0 +1,19 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
NUMERALS = {
|
4
|
+
1000 => 'M',
|
5
|
+
900 => 'CM',
|
6
|
+
500 => 'D',
|
7
|
+
400 => 'CD',
|
8
|
+
100 => 'C',
|
9
|
+
90 => 'XC',
|
10
|
+
50 => 'L',
|
11
|
+
40 => 'XL',
|
12
|
+
10 => 'X',
|
13
|
+
9 => 'IX',
|
14
|
+
5 => 'V',
|
15
|
+
4 => 'IV',
|
16
|
+
1 => 'I',
|
17
|
+
}
|
18
|
+
end
|
19
|
+
end
|
@@ -0,0 +1,18 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
module Particles
|
4
|
+
ALI = "ali"
|
5
|
+
C = "c"
|
6
|
+
CE = "ce"
|
7
|
+
CUMQUE = "cumque"
|
8
|
+
DAM = "dam"
|
9
|
+
DEM = "dem"
|
10
|
+
LIBET = "libet"
|
11
|
+
NAM = "nam"
|
12
|
+
PIAM = "piam"
|
13
|
+
QUAM = "quam"
|
14
|
+
QUE = "que"
|
15
|
+
VIS = "vis"
|
16
|
+
end
|
17
|
+
end
|
18
|
+
end
|
@@ -0,0 +1,46 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
PERSONAL_PRONOUNS = { "ego" => [[:ego, 1, 1]],
|
4
|
+
"egomet" => [[:ego, 1, 1]],
|
5
|
+
"mei" => [[:ego, 2, 1]],
|
6
|
+
"meimet" => [[:ego, 2, 1]],
|
7
|
+
"mihi" => [[:ego, 3, 1]],
|
8
|
+
"mihimet" => [[:ego, 3, 1]],
|
9
|
+
"me" => [[:ego, 4, 1], ["ego", 6, 1]],
|
10
|
+
"memet" => [[:ego, 4, 1], ["ego", 6, 1]],
|
11
|
+
"mecum" => [[:ego, 6, 1]],
|
12
|
+
|
13
|
+
"tu" => [[:tu, 1, 1]],
|
14
|
+
"tute" => [[:tu, 1, 1]],
|
15
|
+
"tui" => [[:tu, 2, 1]],
|
16
|
+
"tibi" => [[:tu, 3, 1]],
|
17
|
+
"tibimet" => [[:tu, 3, 1]],
|
18
|
+
"te" => [[:tu, 4, 1], ["tu", 6, 1]],
|
19
|
+
"tete" => [[:tu, 4, 1], ["tu", 6, 1]],
|
20
|
+
"tecum" => [[:tu, 6, 1]],
|
21
|
+
|
22
|
+
"sui" => [[:se, 2, 1], ["se", 2, 2]],
|
23
|
+
"sibi" => [[:se, 3, 1], ["se", 3, 2]],
|
24
|
+
"sese" => [[:se, 4, 1], ["se", 4, 2]],
|
25
|
+
"se" => [[:se, 4, 1], ["se", 6, 1], ["se", 4, 2], ["se", 6, 2]],
|
26
|
+
"secum" => [[:se, 6, 1], ["se", 6, 2]],
|
27
|
+
|
28
|
+
"nos" => [[:nos, 1, 2], ["nos", 4, 2]],
|
29
|
+
"nosmet" => [[:nos, 1, 2], ["nos", 4, 2]],
|
30
|
+
"nostri" => [[:nos, 2, 2]],
|
31
|
+
"nostrum" => [[:nos, 2, 2]],
|
32
|
+
"nobis" => [[:nos, 3, 2], ["nos", 6, 2]],
|
33
|
+
"nobismet" => [[:nos, 3, 2], ["nos", 6, 2]],
|
34
|
+
"nobiscum" => [[:nos, 6, 2]],
|
35
|
+
|
36
|
+
"vos" => [[:vos, 1, 2], ["vos", 4, 2]],
|
37
|
+
"vosmet" => [[:vos, 1, 2], ["vos", 4, 2]],
|
38
|
+
"vestri" => [[:vos, 2, 2]],
|
39
|
+
"vestrum" => [[:vos, 2, 2]],
|
40
|
+
"vostrum" => [[:vos, 2, 2]],
|
41
|
+
"vobis" => [[:vos, 3, 2], ["vos", 6, 2]],
|
42
|
+
"vobismet" => [[:vos, 3, 2], ["vos", 6, 2]],
|
43
|
+
"vobiscum" => [[:vos, 6, 2]],
|
44
|
+
}
|
45
|
+
end
|
46
|
+
end
|
@@ -0,0 +1,34 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
module Phonology
|
4
|
+
|
5
|
+
LETTERS = { vowel: %w(a e i o u y),
|
6
|
+
long_vowel: %w(ā ē ī ō ū),
|
7
|
+
short_vowel: %w(ă ĕ ĭ ŏ ŭ),
|
8
|
+
diphtong: %w(ae au ei eu oe ),
|
9
|
+
consonant: %w(b c d f gu g h j k l m n p qu r s t v x z),
|
10
|
+
double_consonant: %w(x z),
|
11
|
+
sonant: %w(l m n r),
|
12
|
+
semivowel: %W(i u),
|
13
|
+
|
14
|
+
muta: %w(b d g p t c ph th ch),
|
15
|
+
liquida: %w(l r),
|
16
|
+
nasal: %w(m n),
|
17
|
+
spirant: %w(f v s h ),
|
18
|
+
|
19
|
+
labial: %w(b ph p f v m),
|
20
|
+
aspirant: %w(ph th ch),
|
21
|
+
dental: %w(d th t s n l ), #alveolar
|
22
|
+
labiovelar: %w(gu qu),
|
23
|
+
velar: %w(n g c k), #guttural
|
24
|
+
glottal: %w(h),
|
25
|
+
|
26
|
+
media: %w(b d gu g),
|
27
|
+
tenuis: %w(p t qu c k),
|
28
|
+
}
|
29
|
+
|
30
|
+
PHONEMES = LETTERS
|
31
|
+
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
@@ -0,0 +1,48 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
PREPOSITIONS = { "in" =>[true, true, false],
|
4
|
+
"sub" =>[true, true, false],
|
5
|
+
"super" =>[true, true, false],
|
6
|
+
"ad" =>[true, false, false],
|
7
|
+
"a" =>[false, true, false],
|
8
|
+
"ab" =>[false, true, false],
|
9
|
+
"abs" =>[false, true, false],
|
10
|
+
"e" =>[false, true, false],
|
11
|
+
"ex" =>[false, true, false],
|
12
|
+
"de" =>[false, true, false],
|
13
|
+
"cum" =>[false, true, true],
|
14
|
+
"coram" =>[false, true, true],
|
15
|
+
"palam" =>[false, true, false],
|
16
|
+
"sine" =>[false, true, false],
|
17
|
+
"pro" =>[false, true, false],
|
18
|
+
"prae" =>[false, true, false],
|
19
|
+
"adversus" =>[true, false, true],
|
20
|
+
"adversum" =>[true, false, true],
|
21
|
+
"apud" =>[true, false, false],
|
22
|
+
"circa" =>[true, false, false],
|
23
|
+
"circum" =>[true, false, true],
|
24
|
+
"citra" =>[true, false, false],
|
25
|
+
"erga" =>[true, false, false],
|
26
|
+
"extra" =>[true, false, false],
|
27
|
+
"infra" =>[true, false, false],
|
28
|
+
"inter" =>[true, false, false],
|
29
|
+
"intra" =>[true, false, false],
|
30
|
+
"iuxta" =>[true, false, false],
|
31
|
+
"ob" =>[true, false, false],
|
32
|
+
"penes" =>[true, false, true],
|
33
|
+
"per" =>[true, false, false],
|
34
|
+
"post" =>[true, false, false],
|
35
|
+
"praeter" =>[true, false, false],
|
36
|
+
"prope" =>[true, false, false],
|
37
|
+
"propter" =>[true, false, false],
|
38
|
+
"secundum" =>[true, false, true],
|
39
|
+
"supra" =>[true, false, false],
|
40
|
+
"trans" =>[true, false, false],
|
41
|
+
"ultra" =>[true, false, false],
|
42
|
+
"ante" =>[true, false, true],
|
43
|
+
"contra" =>[true, false, true],
|
44
|
+
"circiter" =>[true, false, true],
|
45
|
+
"cis" =>[true, false, false]
|
46
|
+
}
|
47
|
+
end
|
48
|
+
end
|
@@ -0,0 +1,151 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
module RegExps
|
4
|
+
IRREGULAR_VERBS = {
|
5
|
+
esse: { praesens: [
|
6
|
+
/^(?<prefix>|ab|ad|de|in|inter|ob|prae|super|prod?)
|
7
|
+
(?<stem>e?s|er)
|
8
|
+
(?<thematic>(?<=[rs])u|(?<=r)i|)
|
9
|
+
(?<extension>se(?=\w+)|(?<=s)i|(?<=r)a|)
|
10
|
+
(?<ending>(?<!u)o|m|s|(?<!^e)t|mus|tis|nto?|te|to|tote|se|)$/xi ],
|
11
|
+
perfectum: [
|
12
|
+
/^(?<prefix>|ab?|ad|af|de|inter|ob|of|prae|super|pro)
|
13
|
+
(?<stem>fu)
|
14
|
+
(?<extension>isse|era|eri?|)
|
15
|
+
(?<ending>o|m|s|t|mus|tis|nt|i|isti|it|imus|istis|erunt|isse)$/xi ]
|
16
|
+
},
|
17
|
+
|
18
|
+
posse: { praesens: [
|
19
|
+
/^(?<prefix>)
|
20
|
+
(?<stem>pote[sr]|poss?)
|
21
|
+
(?<thematic>(?<=[rs])u|(?<=r)i|)
|
22
|
+
(?<extension>se(?=.+)|(?<=s)i|(?<=r)a|)
|
23
|
+
(?<ending>o|m|s|(?<!^pos)t|mus|tis|nt|se|)$/xi ],
|
24
|
+
perfectum: [
|
25
|
+
/^(?<prefix>)
|
26
|
+
(?<stem>potu)
|
27
|
+
(?<extension>isse|era|eri?|)
|
28
|
+
(?<ending>o|m|s|t|mus|tis|nt|i|isti|it|imus|istis|erunt|isse)$/xi ]
|
29
|
+
},
|
30
|
+
|
31
|
+
ferre: { praesens: [
|
32
|
+
/^(?<prefix>|a[df]|au|con|de|dif|ef|in|of|per|prae|pro|re|trans)
|
33
|
+
(?<stem>fer)
|
34
|
+
(?<thematic>|e(?=ba)|i(?=.+)|u(?=nt))
|
35
|
+
(?<extension>|e(?=\w+)|ba|a|re(?=.+))
|
36
|
+
(?<ending>m|o|s|te?o?|tote|mu[rs]|tis|nto?|o?r|ris|n?tur|mini|r[ie]|)$/xi,
|
37
|
+
|
38
|
+
/^(?<prefix>|a[df]|au|con|de|dif|ef|in|of|per|prae|pro|re|trans)
|
39
|
+
(?<stem>fer)
|
40
|
+
(?<thematic>e|u)
|
41
|
+
(?<extension>nt?|nd)
|
42
|
+
(?<ending>s|is|i|em|e|es|ium|ibus|ia|us|o|um|[oa]rum|is|os|a|ae|am|as)$/xi
|
43
|
+
],
|
44
|
+
perfectum: [
|
45
|
+
/^(?<prefix>|ab?|ad|at|af|con|de|in|inter|ob|of|per|prae|super|pro)
|
46
|
+
(?<stem>tul)
|
47
|
+
(?<extension>isse|era|eri?|)
|
48
|
+
(?<ending>o|m|s|t|mus|tis|nt|i|isti|it|imus|istis|erunt|isse)$/xi ],
|
49
|
+
ppp: [
|
50
|
+
/^(?<prefix>|ab?|ad|at|af|al|con|de|in|inter|ob|of|per|prae|super|pro)
|
51
|
+
(?<stem>lat)
|
52
|
+
(?<extensiodn>ur|)
|
53
|
+
(?<ending>us|i|o|um|e|[oa]rum|is|os|a|ae|am|as)$/xi ],
|
54
|
+
},
|
55
|
+
|
56
|
+
ire: { praesens: [
|
57
|
+
# prefix ven deleted due to its conflicting behavior with venio
|
58
|
+
/^(?<prefix>|ab|ex|red|inter|ob|per|ad|in|sub|praeter|circum|trans)
|
59
|
+
(?<stem>i)
|
60
|
+
(?<extension>|ba?|re)
|
61
|
+
(?<thematic>|(?<=b)[ei]|(?<=b)u(?!s))
|
62
|
+
(?<ending>(?<!i)m|o|s|te?o?|tote|mu[rs]|nto?|r|ris|n?tur|mini|tis|re|ri)$/xi ,
|
63
|
+
|
64
|
+
/^(?<prefix>|ab|ex|red|inter|ob|per|ad|in|sub|praeter|circum|trans)
|
65
|
+
(?<stem>e)
|
66
|
+
(?<extension>|a)
|
67
|
+
(?<thematic>|u)
|
68
|
+
(?<ending>(?<!u)m|or?|s|(?<!e)t|mu[rs]|tis|nto?|re|r|ris|n?tur|mini)$/xi,
|
69
|
+
|
70
|
+
/^(?<prefix>|ab|ex|red|inter|per|ob|ad|in|sub|praeter|circum|trans)
|
71
|
+
(?<stem>e(?=u)|i(?=ens))
|
72
|
+
(?<thematic>e|u)
|
73
|
+
(?<extension>nt?|nd)
|
74
|
+
(?<ending>s|is|i|em|e|es|ium|ibus|ia|us|o|um|[oa]rum|is|os|a|ae|am|as)$/xi
|
75
|
+
],
|
76
|
+
perfectum: [
|
77
|
+
/^(?<prefix>|ab|ex|red|inter|per|ob|ad|in|sub|praeter|circum|trans)
|
78
|
+
(?<stem>i)
|
79
|
+
(?<extension>|er[aiu]?|sse)
|
80
|
+
(?<ending>(?<!interi)m|o|s|t|i?mus|i|s?tis?|it|erunt|sse|nt)$/xi,
|
81
|
+
|
82
|
+
/^(?<prefix>qu|nequ)
|
83
|
+
(?<stem>iv?)
|
84
|
+
(?<extension>|sse|er[aiu]?|)
|
85
|
+
(?<ending>m|o|s|t|mus|tis|nt|it?|s?tis?|erunt|sse)$/xi,
|
86
|
+
],
|
87
|
+
ppp: [
|
88
|
+
# ending a taken out - we don't want the clash with ita for now (itura still working)
|
89
|
+
/^(?<prefix>|ab|ex|red|inter|per|ad|ob|in|sub|praeter|circum|trans)
|
90
|
+
(?<stem>it)
|
91
|
+
(?<extension>ur|)
|
92
|
+
(?<ending>us|i|o|um|e|[oa]rum|is|os|(?<!it)a|(?<=init)a|ae|am|as)$/xi ]
|
93
|
+
},
|
94
|
+
|
95
|
+
velle: { praesens: [
|
96
|
+
/^(?<stem>v[eou]l|vi)
|
97
|
+
(?<thematic>|e|u(?=[nm]))
|
98
|
+
(?<extension>|i|a|e|ba|le)
|
99
|
+
(?<ending>o|m|s|t|mus|tis|nt|le)$/xi,
|
100
|
+
],
|
101
|
+
perfectum: [
|
102
|
+
/^(?<stem>volu)
|
103
|
+
(?<extension>|er|er[aio]|isse)
|
104
|
+
(?<ending>i|istis?|it|imus|erunt|isse|o|m|s|t|mus|tis|nt)$/xi,
|
105
|
+
],
|
106
|
+
},
|
107
|
+
|
108
|
+
nolle: { praesens: [
|
109
|
+
/^(?<stem>nol)
|
110
|
+
(?<thematic>|e|u(?=[mn])|i(?=t))
|
111
|
+
(?<extension>|i|a|e|ba|le)
|
112
|
+
(?<ending>o|m|s|t|mus|tis|nt|le|i|te|tote|to)$/xi,
|
113
|
+
],
|
114
|
+
perfectum: [
|
115
|
+
/^(?<stem>nolu)
|
116
|
+
(?<extension>|er|er[aio]|isse)
|
117
|
+
(?<ending>i|istis?|it|imus|erunt|isse|o|m|s|t|mus|tis|nt)$/xi,
|
118
|
+
]},
|
119
|
+
|
120
|
+
malle: { praesens: [
|
121
|
+
/^(?<stem>mal|mavi|mavul)
|
122
|
+
(?<thematic>|e|u(?=[mn]))
|
123
|
+
(?<extension>|i|a|e|ba|le)
|
124
|
+
(?<ending>o|m|s|t|mus|tis|nt|le)$/xi,
|
125
|
+
],
|
126
|
+
perfectum: [
|
127
|
+
/^(?<stem>malu)
|
128
|
+
(?<extension>|er|er[aio]|isse)
|
129
|
+
(?<ending>i|istis?|it|imus|erunt|isse|o|m|s|t|mus|tis|nt)$/xi,
|
130
|
+
]},
|
131
|
+
|
132
|
+
edere: { praesens: [],
|
133
|
+
perfectum: []},
|
134
|
+
|
135
|
+
fieri: { praesens: [
|
136
|
+
/^(?<stem>fi)
|
137
|
+
(?<thematic>|e(?=[rb])|u(?=n))
|
138
|
+
(?<extension>a|e(?!r)|re|ba|)
|
139
|
+
(?<ending>o|m|s|t|mus|tis|nt|te|ri|)$/xi
|
140
|
+
],
|
141
|
+
},
|
142
|
+
}
|
143
|
+
|
144
|
+
PRONOUNS = /^(?<prefixed_particle>ali(?=c|q)|un[aiou].*?(?=[cq]u))?
|
145
|
+
(?<stem>qu|hu?|cu|ill|ist|ips|i(?!am$)|e|ute?r)
|
146
|
+
(?<ending>e|s|ius|i|[uae]m|[au]n|[aoi]s|ibus|ae?|o|[oa]ru[nm]|i[dc]|[ou]?d|)
|
147
|
+
(?<particle>c|dam|(?<!qui)dem|que|cumque|piam|libet|vis|quam|piam|nam|quid|\k<stem>\k<ending>)?
|
148
|
+
(?<suffix>(?<=^quo|^qua|^quibus)cum)?$/xi
|
149
|
+
end
|
150
|
+
end
|
151
|
+
end
|
@@ -0,0 +1,32 @@
|
|
1
|
+
module LLT
|
2
|
+
module Constants
|
3
|
+
# word => homophonous_forms?
|
4
|
+
|
5
|
+
SUBJUNCTIONS = {"ut" => false,
|
6
|
+
"uti" => false,
|
7
|
+
"cum" => false,
|
8
|
+
"ne" => false,
|
9
|
+
"quamquam" => false,
|
10
|
+
"dum" => false,
|
11
|
+
"quia" => false,
|
12
|
+
"quoad" => false,
|
13
|
+
"quoadusque" => false,
|
14
|
+
"quoniam" => false,
|
15
|
+
"postquam" => false,
|
16
|
+
"antequam" => false,
|
17
|
+
"si" => false,
|
18
|
+
"ubi" => false,
|
19
|
+
"quod" => false,
|
20
|
+
"quamdiu" => false,
|
21
|
+
"quantum" => false,
|
22
|
+
"nisi" => false,
|
23
|
+
"-ne" => false,
|
24
|
+
"unde" => false,
|
25
|
+
"etiamsi" => false,
|
26
|
+
"tamquam" => false,
|
27
|
+
"utrum" => false,
|
28
|
+
"quare" => true,
|
29
|
+
"quodsi" => false,
|
30
|
+
"quin" => false}
|
31
|
+
end
|
32
|
+
end
|
@@ -0,0 +1,148 @@
|
|
1
|
+
#encoding: UTF-8
|
2
|
+
|
3
|
+
module LLT
|
4
|
+
module Constants
|
5
|
+
module Endings
|
6
|
+
class Verb
|
7
|
+
# all nil values are wildcards to keep the index in the right order
|
8
|
+
SECONDARY = [ "i", "isti", "it", "imus", "istis", "erunt" ]
|
9
|
+
|
10
|
+
PRIMARY_O_ACTIVUM = ["o", "s", "t", "mus", "tis", "nt" ]
|
11
|
+
PRIMARY_M_ACTIVUM = ["m", "s", "t", "mus", "tis", "nt" ]
|
12
|
+
PRIMARY_OR_PASSIVUM = ["or", "ris", "tur", "mur", "mini", "ntur" ]
|
13
|
+
PRIMARY_R_PASSIVUM = ["r", "ris", "tur", "mur", "mini", "ntur" ]
|
14
|
+
|
15
|
+
IMPERATIVUM_ACTIVUM_PRAESENS = [ nil, "", nil, nil, "te", nil ]
|
16
|
+
IMPERATIVUM_ACTIVUM_PRAESENS_C_M = [ nil, "e", nil, nil, "te", nil ]
|
17
|
+
IMPERATIVUM_PASSIVUM_PRAESENS = [ nil, "re", nil, nil, "mini", nil ]
|
18
|
+
|
19
|
+
IMPERATIVUM_ACTIVUM_FUTURUM = [ nil, "to", "to", nil, "tote", "nto" ]
|
20
|
+
IMPERATIVUM_PASSIVUM_FUTURUM = [ nil, "tor", "tor", nil, nil, "ntor" ]
|
21
|
+
|
22
|
+
class Praesens
|
23
|
+
class << self
|
24
|
+
private
|
25
|
+
|
26
|
+
def a1; PRIMARY_O_ACTIVUM; end
|
27
|
+
def a2; PRIMARY_M_ACTIVUM; end
|
28
|
+
def p1; PRIMARY_R_PASSIVUM; end
|
29
|
+
def p2; PRIMARY_OR_PASSIVUM; end
|
30
|
+
def p3sg; [nil, nil, "tur", nil, nil, nil]; end
|
31
|
+
def iap1; IMPERATIVUM_ACTIVUM_PRAESENS; end
|
32
|
+
def iap2; IMPERATIVUM_ACTIVUM_PRAESENS_C_M; end
|
33
|
+
def ipp ; IMPERATIVUM_PASSIVUM_PRAESENS; end
|
34
|
+
def ifa ; IMPERATIVUM_ACTIVUM_FUTURUM; end
|
35
|
+
def ifp ; IMPERATIVUM_PASSIVUM_FUTURUM; end
|
36
|
+
def nils; [nil, nil, nil, nil, nil, nil]; end
|
37
|
+
def praes_ind_con; a1 + p2 + a2 + p1; end
|
38
|
+
def praes_imp_to_future_ind; ipp + a2 + p1 + a2 + p1 + nils + nils; end
|
39
|
+
def future_con_and_imp; nils + nils + ifa + ifp; end
|
40
|
+
end
|
41
|
+
|
42
|
+
# these "compositions" could be refactored one day to something like
|
43
|
+
# A = praesens_a + imperfect_a + future_a, for better readability...
|
44
|
+
# pIa pIp pCa pCp pIMa pIMp iIa iIp iCa iCp nil nil fIa aIp nil nil fIMa fIMp
|
45
|
+
A = praes_ind_con + iap1 + praes_imp_to_future_ind + a1 + p2 + future_con_and_imp
|
46
|
+
E = A
|
47
|
+
C = praes_ind_con + iap2 + praes_imp_to_future_ind + a2 + p1 + future_con_and_imp
|
48
|
+
I = praes_ind_con + iap1 + praes_imp_to_future_ind + a2 + p1 + future_con_and_imp
|
49
|
+
M = C
|
50
|
+
|
51
|
+
def self.get(inflection_class)
|
52
|
+
const_get(case inflection_class
|
53
|
+
when 1 then :A
|
54
|
+
when 2 then :E
|
55
|
+
when 3 then :C
|
56
|
+
when 4 then :I
|
57
|
+
when 5 then :M
|
58
|
+
end)
|
59
|
+
end
|
60
|
+
end
|
61
|
+
|
62
|
+
class IrregularPraesens < Praesens
|
63
|
+
a3 = ["m", "", "t", "mus", "tis", "nt" ]
|
64
|
+
a4 = ["o", "", "t", "mus", "tis", "nt" ]
|
65
|
+
iap3 = [ nil, "i", nil, nil, "te", nil ]
|
66
|
+
nils_3 = nils + nils + nils
|
67
|
+
same_forms_of_esse_and_edere = nils + a2 + nils + iap1 + nils + a2 + nils + a2 + nils_3 + a1 + nils_3 + ifa + nils
|
68
|
+
|
69
|
+
ESSE = a3 + same_forms_of_esse_and_edere
|
70
|
+
POSSE = a3 + nils + a2 + nils_3 + a2 + nils + a2 + nils_3 + a1 + nils_3 + nils + nils
|
71
|
+
FERRE = a1 + p2 + a2 + p1 + iap1 + praes_imp_to_future_ind + a2 + p1 + future_con_and_imp
|
72
|
+
VELLE = a1 + nils + a2 + nils_3 + a2 + nils + a2 + nils_3 + a2 + nils_3 + nils + nils
|
73
|
+
NOLLE = a1 + nils + a2 + nils + iap3 + nils +
|
74
|
+
a2 + nils + a2 + nils_3 +
|
75
|
+
a2 + nils + nils + nils + ifa + nils
|
76
|
+
MALLE = VELLE
|
77
|
+
# passive of ire because of composita
|
78
|
+
IRE = a1 + p2 + a2 + p1 + iap1 + praes_imp_to_future_ind + a1 + p2 + future_con_and_imp
|
79
|
+
EDERE = a4 + p3sg + a2 + p3sg + iap1 + nils +
|
80
|
+
a2 + p3sg + a2 + p3sg + nils + nils +
|
81
|
+
a2 + p3sg + nils + nils + ifa + nils
|
82
|
+
# active endings!
|
83
|
+
FIERI = nils + a1 + nils + a2 + nils + nils +
|
84
|
+
nils + a2 + nils + a2 + nils + nils +
|
85
|
+
nils + a2 + nils + nils + nils + nils
|
86
|
+
|
87
|
+
def self.get(inflection_class)
|
88
|
+
const_get(inflection_class.upcase.to_sym)
|
89
|
+
end
|
90
|
+
end
|
91
|
+
|
92
|
+
class PraesensInfinitivum < Praesens
|
93
|
+
A = ["re", "ri"]
|
94
|
+
E = A
|
95
|
+
C = ["re", "i"]
|
96
|
+
I = A
|
97
|
+
M = C
|
98
|
+
end
|
99
|
+
|
100
|
+
class IrregularPraesensInfinitivum < IrregularPraesens
|
101
|
+
ESSE = ["se"]
|
102
|
+
POSSE = ["se"]
|
103
|
+
FERRE = ["re", "ri"]
|
104
|
+
VELLE = ["le"]
|
105
|
+
NOLLE = VELLE
|
106
|
+
MALLE = VELLE
|
107
|
+
IRE = FERRE
|
108
|
+
EDERE = ["se"]
|
109
|
+
FIERI = [nil, "ri"]
|
110
|
+
end
|
111
|
+
|
112
|
+
class Perfectum
|
113
|
+
def self.get
|
114
|
+
a1 = PRIMARY_O_ACTIVUM
|
115
|
+
a2 = PRIMARY_M_ACTIVUM
|
116
|
+
a3 = SECONDARY
|
117
|
+
|
118
|
+
a3 + a2 + a2 + a2 + a1
|
119
|
+
end
|
120
|
+
end
|
121
|
+
|
122
|
+
class IrregularPerfectum < Perfectum
|
123
|
+
end
|
124
|
+
|
125
|
+
class Metrical < Verb
|
126
|
+
O = "ō"
|
127
|
+
SECONDARY = [ "ī", "istī", "it", "imus", "istis", "ērunt" ]
|
128
|
+
PRIMARY_PASSIVUM_ENDING_WITHOUT_FIRST = [ "rĭs", "tŭr", "mŭr", "mĭnī", "ntŭr" ]
|
129
|
+
PRIMARY_ACTIVUM_ENDINGS_WITHOUT_FIRST = [ "s", "t", "mŭs", "tĭs", "nt" ]
|
130
|
+
|
131
|
+
IMPERATIVUM_PASSIVUM_PRAESENS = [ nil, "re", nil, nil, "minī", nil ]
|
132
|
+
|
133
|
+
IMPERATIVUM_ACTIVUM_FUTURUM = [ nil, "tō", "tō", nil, "tōte", "ntō" ]
|
134
|
+
IMPERATIVUM_PASSIVUM_FUTURUM = [ nil, "tor", "tor", nil, nil, "ntor" ]
|
135
|
+
end
|
136
|
+
|
137
|
+
class PerfectumInfinitivum
|
138
|
+
def self.get(*args)
|
139
|
+
["isse"]
|
140
|
+
end
|
141
|
+
end
|
142
|
+
|
143
|
+
class IrregularPerfectumInfinitivum < PerfectumInfinitivum
|
144
|
+
end
|
145
|
+
end
|
146
|
+
end
|
147
|
+
end
|
148
|
+
end
|