Created
July 16, 2013 09:58
-
-
Save johnjcamilleri/6007397 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
abstract Camel = { | |
cat | |
Kind ; | |
Action Kind; | |
Component Kind; | |
S; | |
fun | |
endpoint : Kind ; | |
standard : Kind ; | |
database : Component endpoint ; | |
database_oracle : Component endpoint ; | |
read : Action endpoint ; | |
write : Action endpoint ; | |
VerbF : (k : Kind) -> Action k -> String -> Component k -> S; | |
} | |
concrete CamelEng of Camel = { | |
flags | |
startcat=S; | |
oper | |
s : Str -> { s : Str } = \str -> { s = str }; | |
the : Str -> { s : Str } = \str -> s ("the" ++ str) ; | |
lincat | |
Kind, Action, Component, S = {s:Str}; | |
lin | |
standard = s "ignore" ; | |
endpoint = s "ignore" ; | |
database = the "database" ; | |
database_oracle = the "Oracle database" ; | |
read = s "read" ; | |
write = s "write" ; | |
VerbF _ action str compo = s (action.s ++ "the" ++ str.s ++ "in" ++ compo.s) ; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment