MCPcopy
hub / github.com/kubernetes/kubectl / Close

Method Close

pkg/util/interrupt/interrupt.go:62–68  ·  view source on GitHub ↗

Close executes all the notification handlers if they have not yet been executed.

()

Source from the content-addressed store, hash-verified

60
61// Close executes all the notification handlers if they have not yet been executed.
62func (h *Handler) Close() {
63 h.once.Do(func() {
64 for _, fn := range h.notify {
65 fn()
66 }
67 })
68}
69
70// Signal is called when an os.Signal is received, and guarantees that all notifications
71// are executed, then the final handler is executed. This function should only be called once

Callers 15

RunMethod · 0.95
TestFileServingFunction · 0.80
TestAPIRequestsFunction · 0.80
TestPathHandlingFunction · 0.80
rawFunction · 0.80
initProfilingFunction · 0.80
flushProfilingFunction · 0.80
DefaultConsumeRequestFunction · 0.80
mockConsumeRequestMethod · 0.80
copyToPodMethod · 0.80
initReadFromMethod · 0.80

Calls

no outgoing calls

Tested by 15

TestFileServingFunction · 0.64
TestAPIRequestsFunction · 0.64
TestPathHandlingFunction · 0.64
mockConsumeRequestMethod · 0.64
TestBadTarFunction · 0.64
TestUntarFunction · 0.64
TestUntar_SingleFileFunction · 0.64
createTmpFileFunction · 0.64
TestTaintFunction · 0.64
TestCordonFunction · 0.64
TestDrainFunction · 0.64