ImplementInterface declares that this interface implements another interface. This is the interface-to-interface equivalent of Class.Implements.
(other *Interface)
| 396 | // ImplementInterface declares that this interface implements another interface. |
| 397 | // This is the interface-to-interface equivalent of Class.Implements. |
| 398 | func (iface *Interface) ImplementInterface(other *Interface) { |
| 399 | iface.relationsL.Lock() |
| 400 | iface.interfaces[other.TypeName()] = other |
| 401 | iface.relationsL.Unlock() |
| 402 | |
| 403 | // Also register this interface as an implementor of the other interface, |
| 404 | // so possibleTypes includes it. |
| 405 | other.addImplementor(iface.name) |
| 406 | } |
| 407 | |
| 408 | // Implementors returns a snapshot of the type names that implement this interface. |
| 409 | func (iface *Interface) Implementors() map[string]struct{} { |
nothing calls this directly
no test coverage detected