Home / Function/ findNear() — netty Function Reference

findNear() — netty Function Reference

Architecture documentation for the findNear() function in ConcurrentSkipListIntObjMultimap.java from the netty codebase.

Function java CommonUtil Concurrent calls 3 called by 6

Entity Profile

Dependency Diagram

graph TD
  73583e8b_7c0e_6565_1f6c_c76bfaba5388["findNear()"]
  d9a8da36_aab9_ab33_dc67_870b34dcd270["ConcurrentSkipListIntObjMultimap"]
  73583e8b_7c0e_6565_1f6c_c76bfaba5388 -->|defined in| d9a8da36_aab9_ab33_dc67_870b34dcd270
  053ce890_e4be_74c8_2588_81d60d10b2be["findNearEntry()"]
  053ce890_e4be_74c8_2588_81d60d10b2be -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  0a1adfa5_a564_963d_5507_df241083136e["lowerKey()"]
  0a1adfa5_a564_963d_5507_df241083136e -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  0e9b6d92_d870_2ebd_c53a_c2fbc2723621["floorKey()"]
  0e9b6d92_d870_2ebd_c53a_c2fbc2723621 -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  946c8b82_8e3a_a30c_9e83_adbb8b1a28ff["ceilingKey()"]
  946c8b82_8e3a_a30c_9e83_adbb8b1a28ff -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  6e005512_5be7_3cf8_1817_0e8621923938["higherKey()"]
  6e005512_5be7_3cf8_1817_0e8621923938 -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  0516e48d_e917_da11_8922_79ca766dc67f["pollCeilingEntry()"]
  0516e48d_e917_da11_8922_79ca766dc67f -->|calls| 73583e8b_7c0e_6565_1f6c_c76bfaba5388
  ff16b6d0_47d8_82e1_a033_998f1f35233f["findPredecessor()"]
  73583e8b_7c0e_6565_1f6c_c76bfaba5388 -->|calls| ff16b6d0_47d8_82e1_a033_998f1f35233f
  14308445_2437_e26b_41bb_c7458d3b14e0["unlinkNode()"]
  73583e8b_7c0e_6565_1f6c_c76bfaba5388 -->|calls| 14308445_2437_e26b_41bb_c7458d3b14e0
  7e2d9d49_a28d_4cbe_a83c_2187034997b4["cpr()"]
  73583e8b_7c0e_6565_1f6c_c76bfaba5388 -->|calls| 7e2d9d49_a28d_4cbe_a83c_2187034997b4
  style 73583e8b_7c0e_6565_1f6c_c76bfaba5388 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

common/src/main/java/io/netty/util/concurrent/ConcurrentSkipListIntObjMultimap.java lines 1047–1079

    final Node<V> findNear(int key, int rel) {
        if (key == noKey) {
            throw new IllegalArgumentException();
        }
        Node<V> result;
        outer: for (Node<V> b;;) {
            if ((b = findPredecessor(key)) == null) {
                result = null;
                break;                   // empty
            }
            for (;;) {
                Node<V> n; int k; int c;
                if ((n = b.next) == null) {
                    result = (rel & LT) != 0 && b.key != noKey ? b : null;
                    break outer;
                } else if ((k = n.key) == noKey) {
                    break;
                } else if (n.val == null) {
                    unlinkNode(b, n, noKey);
                } else if (((c = cpr(key, k)) == 0 && (rel & EQ) != 0) ||
                         (c < 0 && (rel & LT) == 0)) {
                    result = n;
                    break outer;
                } else if (c <= 0 && (rel & LT) != 0) {
                    result = b.key != noKey ? b : null;
                    break outer;
                } else {
                    b = n;
                }
            }
        }
        return result;
    }

Domain

Subdomains

Frequently Asked Questions

What does findNear() do?
findNear() is a function in the netty codebase, defined in common/src/main/java/io/netty/util/concurrent/ConcurrentSkipListIntObjMultimap.java.
Where is findNear() defined?
findNear() is defined in common/src/main/java/io/netty/util/concurrent/ConcurrentSkipListIntObjMultimap.java at line 1047.
What does findNear() call?
findNear() calls 3 function(s): cpr, findPredecessor, unlinkNode.
What calls findNear()?
findNear() is called by 6 function(s): ceilingKey, findNearEntry, floorKey, higherKey, lowerKey, pollCeilingEntry.

Analyze Your Own Codebase

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

Try Supermodel Free