Set saves data in the context.
(key string, val any)
| 465 | |
| 466 | // Set saves data in the context. |
| 467 | func (c *Context) Set(key string, val any) { |
| 468 | c.lock.Lock() |
| 469 | if c.store == nil { |
| 470 | c.store = make(map[string]any) |
| 471 | } |
| 472 | c.store[key] = val |
| 473 | c.lock.Unlock() |
| 474 | } |
| 475 | |
| 476 | // Bind binds path params, query params and the request body into provided type `i`. The default binder |
| 477 | // binds body based on Content-Type header. |
no outgoing calls