Home / Function/ nextLong() — netty Function Reference

nextLong() — netty Function Reference

Architecture documentation for the nextLong() function in EpollSocketChannelConfigTest.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  57c042e3_6d28_e9a2_e661_da772c6b29e2["nextLong()"]
  cbf3710d_0610_b07a_f224_0edbf3495fdf["EpollSocketChannelConfigTest"]
  57c042e3_6d28_e9a2_e661_da772c6b29e2 -->|defined in| cbf3710d_0610_b07a_f224_0edbf3495fdf
  a917c43b_f4f4_6a9c_6c30_9d94eb672c7f["randLong()"]
  a917c43b_f4f4_6a9c_6c30_9d94eb672c7f -->|calls| 57c042e3_6d28_e9a2_e661_da772c6b29e2
  style 57c042e3_6d28_e9a2_e661_da772c6b29e2 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

transport-native-epoll/src/test/java/io/netty/channel/epoll/EpollSocketChannelConfigTest.java lines 80–87

    private static long nextLong(long n) {
        long bits, val;
        do {
           bits = (rand.nextLong() << 1) >>> 1;
           val = bits % n;
        } while (bits - val + (n - 1) < 0L);
        return val;
     }

Domain

Subdomains

Called By

Frequently Asked Questions

What does nextLong() do?
nextLong() is a function in the netty codebase, defined in transport-native-epoll/src/test/java/io/netty/channel/epoll/EpollSocketChannelConfigTest.java.
Where is nextLong() defined?
nextLong() is defined in transport-native-epoll/src/test/java/io/netty/channel/epoll/EpollSocketChannelConfigTest.java at line 80.
What calls nextLong()?
nextLong() is called by 1 function(s): randLong.

Analyze Your Own Codebase

Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.

Try Supermodel Free