diff options
Diffstat (limited to 'types.go')
| -rw-r--r-- | types.go | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/types.go b/types.go new file mode 100644 index 0000000..e785f4c --- /dev/null +++ b/types.go @@ -0,0 +1,25 @@ +package growel + +import "net/http" + +type Context struct { + W http.ResponseWriter + R *http.Request + Params map[string]string +} + +type Handler func(c *Context) + +type Route struct { + method string + parts []string + handler Handler +} + +type Router struct { + routes []Route +} + +type Engine struct { + router *Router +} |
