123456789101112131415161718192021 |
- package binding
- import "net/http"
- type queryBinding struct{}
- func (queryBinding) Name() string {
- return "query"
- }
- func (queryBinding) Bind(req *http.Request, obj interface{}) error {
- values := req.URL.Query()
- if err := mapForm(obj, values); err != nil {
- return err
- }
- return nil
- }
|