WithConfigInterceptor instructs the Providers to accept the GormConfigInterceptor so that users can change config during runtime. This can be useful when some dynamic computations on configs are required.
(interceptor GormConfigInterceptor)
| 19 | // GormConfigInterceptor so that users can change config during runtime. This can |
| 20 | // be useful when some dynamic computations on configs are required. |
| 21 | func WithConfigInterceptor(interceptor GormConfigInterceptor) ProvidersOptionFunc { |
| 22 | return func(options *providersOption) { |
| 23 | options.interceptor = interceptor |
| 24 | } |
| 25 | } |
| 26 | |
| 27 | // WithDrivers instructs the Providers to add new drivers or replace existing |
| 28 | // drivers. (By default, only "mysql", "sqlite", and "clickhouse" drivers are |
no outgoing calls