notifyListeners() — netty Function Reference
Architecture documentation for the notifyListeners() function in DefaultPromise.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 00513e87_934e_6633_22ee_a4fb405c640f["notifyListeners()"] a0080a71_f091_42e0_8a20_424f0bf9d34a["DefaultPromise"] 00513e87_934e_6633_22ee_a4fb405c640f -->|defined in| a0080a71_f091_42e0_8a20_424f0bf9d34a 9c9d5e6f_6ff4_2673_f553_713895ee985f["addListener()"] 9c9d5e6f_6ff4_2673_f553_713895ee985f -->|calls| 00513e87_934e_6633_22ee_a4fb405c640f e23e9563_7378_d834_4886_924c663bd962["addListeners()"] e23e9563_7378_d834_4886_924c663bd962 -->|calls| 00513e87_934e_6633_22ee_a4fb405c640f 6636473d_c073_6689_5a79_bdbd8f601e8b["cancel()"] 6636473d_c073_6689_5a79_bdbd8f601e8b -->|calls| 00513e87_934e_6633_22ee_a4fb405c640f 3d806901_c2cd_5a04_10f4_4cc24e5917c0["setValue0()"] 3d806901_c2cd_5a04_10f4_4cc24e5917c0 -->|calls| 00513e87_934e_6633_22ee_a4fb405c640f cc9ae68c_24a7_07de_3637_ca681cc4b97f["notifyListenersNow()"] 00513e87_934e_6633_22ee_a4fb405c640f -->|calls| cc9ae68c_24a7_07de_3637_ca681cc4b97f 6b17dbfa_0dba_6f1a_183b_cac1eee894d9["safeExecute()"] 00513e87_934e_6633_22ee_a4fb405c640f -->|calls| 6b17dbfa_0dba_6f1a_183b_cac1eee894d9 style 00513e87_934e_6633_22ee_a4fb405c640f fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
common/src/main/java/io/netty/util/concurrent/DefaultPromise.java lines 498–520
private void notifyListeners() {
EventExecutor executor = executor();
if (executor.inEventLoop()) {
final InternalThreadLocalMap threadLocals = InternalThreadLocalMap.get();
final int stackDepth = threadLocals.futureListenerStackDepth();
if (stackDepth < MAX_LISTENER_STACK_DEPTH) {
threadLocals.setFutureListenerStackDepth(stackDepth + 1);
try {
notifyListenersNow();
} finally {
threadLocals.setFutureListenerStackDepth(stackDepth);
}
return;
}
}
safeExecute(executor, new Runnable() {
@Override
public void run() {
notifyListenersNow();
}
});
}
Domain
Subdomains
Source
Frequently Asked Questions
What does notifyListeners() do?
notifyListeners() is a function in the netty codebase, defined in common/src/main/java/io/netty/util/concurrent/DefaultPromise.java.
Where is notifyListeners() defined?
notifyListeners() is defined in common/src/main/java/io/netty/util/concurrent/DefaultPromise.java at line 498.
What does notifyListeners() call?
notifyListeners() calls 2 function(s): notifyListenersNow, safeExecute.
What calls notifyListeners()?
notifyListeners() is called by 4 function(s): addListener, addListeners, cancel, setValue0.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free