summaryrefslogtreecommitdiff
path: root/examples/phrasebook/Sentences.gf
blob: 453db03f81c1cf2eb3743e241aa3eff7f507c896 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
abstract Sentences = Numeral ** {

  cat
    Phrase ;
    Sentence ; Question ; 
    Object ; Item ; Kind ; Quality ; 
    Place ; PlaceKind ; Currency ; Price ; Language ;
    Person ; Action ;

  fun
    -- these phrases are formed here, not in Phrasebook, as they are functorial
    PSentence : Sentence -> Phrase ;
    PQuestion : Question -> Phrase ;

    PObject   : Object   -> Phrase ;
    PKind     : Kind     -> Phrase ;
    PQuality  : Quality  -> Phrase ;
    PNumeral  : Numeral  -> Phrase ;
    PPlace    : Place    -> Phrase ;
    PPlaceKind: PlaceKind-> Phrase ;
    PCurrency : Currency -> Phrase ;
    PPrice    : Price    -> Phrase ;
    PLanguage : Language -> Phrase ;

    Is    : Item -> Quality -> Sentence ;
    IsNot : Item -> Quality -> Sentence ;

    WhetherIs : Item -> Quality -> Question ;
    WhereIs   : Place -> Question ;

    SAction : Action -> Sentence ;
    SNotAction : Action -> Sentence ;
    QAction : Action -> Question ;

    HowMuchCost : Item -> Question ;
    ItCost : Item -> Price -> Sentence ;
    AmountCurrency : Numeral -> Currency -> Price ;

    ObjItem : Item -> Object ;
    ObjNumber : Numeral -> Kind -> Object ;
    
    This, That, These, Those, The, Thes : Kind -> Item ;
    SuchKind : Quality -> Kind -> Kind ;
    Very : Quality -> Quality ;
    Too : Quality -> Quality ;

    ThePlace : PlaceKind -> Place ;

    I, YouFam, YouPol : Person ;

}