SetContext sets a key-value pair in the context map.
(key string, value any)
| 472 | |
| 473 | // SetContext sets a key-value pair in the context map. |
| 474 | func (d *Dispenser) SetContext(key string, value any) { |
| 475 | if d.context == nil { |
| 476 | d.context = make(map[string]any) |
| 477 | } |
| 478 | d.context[key] = value |
| 479 | } |
| 480 | |
| 481 | // GetContext gets the value of a key in the context map. |
| 482 | func (d *Dispenser) GetContext(key string) any { |
no outgoing calls
no test coverage detected