OnGroup is a hook to execute user functions on each group registration. Also you can get group properties by group parameter.
(handler ...OnGroupHandler)
| 257 | // OnGroup is a hook to execute user functions on each group registration. |
| 258 | // Also you can get group properties by group parameter. |
| 259 | func (h *Hooks) OnGroup(handler ...OnGroupHandler) { |
| 260 | h.app.mutex.Lock() |
| 261 | h.onGroup = append(h.onGroup, handler...) |
| 262 | h.app.mutex.Unlock() |
| 263 | } |
| 264 | |
| 265 | // OnGroupName is a hook to execute user functions on each group naming. |
| 266 | // Also you can get group properties by group parameter. |