(addr string)
| 106 | } |
| 107 | |
| 108 | func (s *Server) Run(addr string) error { |
| 109 | httpServer := &http.Server{ |
| 110 | Addr: addr, |
| 111 | Handler: s.Handler(), |
| 112 | } |
| 113 | |
| 114 | log.Printf("Listening for requests on %s...\n", addr) |
| 115 | return httpServer.ListenAndServe() |
| 116 | } |
| 117 | |
| 118 | func (s *Server) collectQueryStringData() http.Handler { |
| 119 | return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) { |