summaryrefslogtreecommitdiff
path: root/examples/foods/ResCze.gf
diff options
context:
space:
mode:
authorjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
committerjohn.j.camilleri <john.j.camilleri@chalmers.se>2013-09-16 07:17:27 +0000
commitf5461eb3d4eb2605b546a4ed202c12bcdaa1f4e4 (patch)
tree946c9e8542b8e8271b6b529a95c0400fa6613cb4 /examples/foods/ResCze.gf
parent8e1c6cca407c82fc09569d80c231b8d256735989 (diff)
Remove contribs and examples
Everything has now been moved to a separate repository at https://github.com/GrammaticalFramework/gf-contrib The contents of the examples folder are build during SetupWeb
Diffstat (limited to 'examples/foods/ResCze.gf')
-rw-r--r--examples/foods/ResCze.gf46
1 files changed, 46 insertions, 0 deletions
diff --git a/examples/foods/ResCze.gf b/examples/foods/ResCze.gf
new file mode 100644
index 000000000..56b4aa6ee
--- /dev/null
+++ b/examples/foods/ResCze.gf
@@ -0,0 +1,46 @@
+-- (c) 2011 Katerina Bohmova under LGPL
+
+resource ResCze = open Prelude in {
+ flags
+ coding = utf8 ;
+ param
+ Number = Sg | Pl ;
+ Gender = Masc | Fem | Neutr;
+ oper
+ NounPhrase : Type =
+ {s : Str ; g : Gender ; n : Number} ;
+ Noun : Type = {s : Number => Str ; g : Gender} ;
+ Adjective : Type = {s : Gender => Number => Str} ;
+
+ det : Number -> Str -> Str -> Str -> Noun -> NounPhrase =
+ \n,m,f,ne,cn -> {
+ s = table {Masc => m ; Fem => f; Neutr => ne} ! cn.g ++
+ cn.s ! n ;
+ g = cn.g ;
+ n = n
+ } ;
+ noun : Str -> Str -> Gender -> Noun =
+ \muz,muzi,g -> {
+ s = table {Sg => muz ; Pl => muzi} ;
+ g = g
+ } ;
+ adjective : (msg,fsg,nsg,mpl,fpl,npl : Str) -> Adjective =
+ \msg,fsg,nsg,mpl,fpl,npl -> {
+ s = table {
+ Masc => table {Sg => msg ; Pl => mpl} ;
+ Fem => table {Sg => fsg ; Pl => fpl} ;
+ Neutr => table {Sg => nsg ; Pl => npl}
+ }
+ } ;
+ regAdj : Str -> Adjective =
+ \mlad ->
+ adjective (mlad+"ý") (mlad+"á") (mlad+"é")
+ (mlad+"é") (mlad+"é") (mlad+"á") ;
+ regnfAdj : Str -> Adjective =
+ \vynikajici ->
+ adjective vynikajici vynikajici vynikajici
+ vynikajici vynikajici vynikajici;
+ copula : Number => Str =
+ table {Sg => "je" ; Pl => "jsou"} ;
+}
+