functor
import Encode FS
export Get Agreement
define
Agreement = {New Encode.domainProduct
init([[masc fem neut]
[sing plur]
[1 2 3]
[nom acc dat gen]
[def indef none]])}
Lexicon = {Dictionary.new}
proc {Enter W Desc}
Lexicon.W := {Agreement encode(Desc $)}
end
proc {Get W I}
I::Agreement.range
{FS.include I Lexicon.W}
end
{Enter mann [[masc 3 sing [nom acc dat]]]}
{Enter mannes [[masc 3 sing gen]]}
{Enter männer [[masc 3 plur [nom acc gen]]]}
{Enter männern [[masc 3 plur dat]]}
{Enter der [[def [[masc sing 3 nom]
[fem sing 3 [dat gen]]
[ plur 3 gen]]]]}
{Enter den [[def [[masc sing 3 acc]
[ plur 3 dat]]]]}
{Enter dem [[def [[[masc neut] sing 3 dat]]]]}
{Enter des [[def [[[masc neut] sing 3 gen]]]]}
{Enter die [[def [[fem sing 3 [nom acc]]
[ plur 3 [nom acc]]]]]}
{Enter das [[def [[neut sing 3 [nom acc]]]]]}
{Enter ein [[indef [[masc sing 3 nom]
[neut sing 3 [nom acc]]]]]}
{Enter einen [[indef [[masc sing 3 acc]]]]}
{Enter einem [[indef [[[masc neut] sing 3 dat]]]]}
{Enter eines [[indef [[[masc neut] sing 3 gen]]]]}
{Enter eine [[indef [[fem sing 3 [nom acc]]]]]}
{Enter einer [[indef [[fem sing 3 [dat gen]]]]]}
{Enter '*no determiner*' none}
{Enter schöne [[none [nom acc] [fem plur]]
[def sing [nom [acc [neut fem]]]]
[indef plur [nom acc]]]}
{Enter schönen [[none [[masc sing [acc gen]]
[fem sing gen]
[plur dat]]]
[def [plur dat gen [masc sing acc]]]
[indef sing [dat gen [masc acc]]]]}
{Enter schöner [[none [[masc sing nom]
[fem sing [dat gen]]
[plur gen]]]
[indef sing masc nom]]}
{Enter schönes [[neut sing [nom acc] [indef none]]]}
{Enter schönem [[[masc neut] sing dat none]]}
end