Mercurial > urweb
comparison demo/more/grid.ur @ 935:2422360c78a3
Dropped in initial aggregate types
author | Adam Chlipala <adamc@hcoop.net> |
---|---|
date | Tue, 15 Sep 2009 09:40:51 -0400 |
parents | 5e8b6fa5b48f |
children | 6966d98c80b5 |
comparison
equal
deleted
inserted
replaced
934:36f787c02287 | 935:2422360c78a3 |
---|---|
8 | 8 |
9 con colMeta = fn (row :: Type) (global_t :: (Type * Type)) => | 9 con colMeta = fn (row :: Type) (global_t :: (Type * Type)) => |
10 {Initialize : transaction global_t.1, | 10 {Initialize : transaction global_t.1, |
11 Handlers : global_t.1 -> colMeta' row global_t.2} | 11 Handlers : global_t.1 -> colMeta' row global_t.2} |
12 | 12 |
13 con aggregateMeta = fn (row :: Type) (acc :: Type) => | |
14 {Initial : acc, | |
15 Step : row -> acc -> acc, | |
16 Display : acc -> xbody} | |
17 | |
13 functor Make(M : sig | 18 functor Make(M : sig |
14 type row | 19 type row |
15 val list : transaction (list row) | 20 val list : transaction (list row) |
16 val new : transaction row | 21 val new : transaction row |
17 val save : {Old : row, New : row} -> transaction unit | 22 val save : {Old : row, New : row} -> transaction unit |
19 | 24 |
20 con cols :: {(Type * Type)} | 25 con cols :: {(Type * Type)} |
21 val cols : $(map (colMeta row) cols) | 26 val cols : $(map (colMeta row) cols) |
22 | 27 |
23 val folder : folder cols | 28 val folder : folder cols |
29 | |
30 con aggregates :: {Type} | |
31 val aggregates : $(map (aggregateMeta row) aggregates) | |
24 end) = struct | 32 end) = struct |
25 style tabl | 33 style tabl |
26 style tr | 34 style tr |
27 style th | 35 style th |
28 style td | 36 style td |