MCPcopy Create free account
hub / github.com/apache/calcite / addThread

Method addThread

core/src/main/java/org/apache/calcite/runtime/Hook.java:155–159  ·  view source on GitHub ↗

Adds a handler for this thread.

(final Consumer<T> handler)

Source from the content-addressed store, hash-verified

153
154 /** Adds a handler for this thread. */
155 public <T> Closeable addThread(final Consumer<T> handler) {
156 //noinspection unchecked
157 threadHandlers.get().add((Consumer<Object>) handler);
158 return () -> removeThread(handler);
159 }
160
161 // CHECKSTYLE: IGNORE 1
162 /** @deprecated Use {@link #addThread(Consumer)}. */

Callers 15

testStdinMethod · 0.80
beforeMethod · 0.80
testHookMethod · 0.80
testMinAggWithDoubleMethod · 0.80
testBindableIntersectMethod · 0.80
testBindableMinusMethod · 0.80
beforeMethod · 0.80
convertSqlToRelMethod · 0.80
fixedTimeStringMethod · 0.80
checkMethod · 0.80

Calls 4

removeThreadMethod · 0.95
functionConsumerMethod · 0.95
addMethod · 0.65
getMethod · 0.65

Tested by 15

testStdinMethod · 0.64
beforeMethod · 0.64
testHookMethod · 0.64
testMinAggWithDoubleMethod · 0.64
testBindableIntersectMethod · 0.64
testBindableMinusMethod · 0.64
beforeMethod · 0.64
convertSqlToRelMethod · 0.64
fixedTimeStringMethod · 0.64
checkMethod · 0.64