Home / Function/ size() — netty Function Reference

size() — netty Function Reference

Architecture documentation for the size() function in InternalThreadLocalMap.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  932336b9_8efe_0945_c2dd_edb6711bdff8["size()"]
  d6ca0ae0_1399_e584_fef6_bfc2f1e3e146["InternalThreadLocalMap"]
  932336b9_8efe_0945_c2dd_edb6711bdff8 -->|defined in| d6ca0ae0_1399_e584_fef6_bfc2f1e3e146
  style 932336b9_8efe_0945_c2dd_edb6711bdff8 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

common/src/main/java/io/netty/util/internal/InternalThreadLocalMap.java lines 172–211

    public int size() {
        int count = 0;

        if (futureListenerStackDepth != 0) {
            count ++;
        }
        if (localChannelReaderStackDepth != 0) {
            count ++;
        }
        if (handlerSharableCache != null) {
            count ++;
        }
        if (typeParameterMatcherGetCache != null) {
            count ++;
        }
        if (typeParameterMatcherFindCache != null) {
            count ++;
        }
        if (stringBuilder != null) {
            count ++;
        }
        if (charsetEncoderCache != null) {
            count ++;
        }
        if (charsetDecoderCache != null) {
            count ++;
        }
        if (arrayList != null) {
            count ++;
        }

        Object v = indexedVariable(VARIABLES_TO_REMOVE_INDEX);
        if (v != null && v != InternalThreadLocalMap.UNSET) {
            @SuppressWarnings("unchecked")
            Set<FastThreadLocal<?>> variablesToRemove = (Set<FastThreadLocal<?>>) v;
            count += variablesToRemove.size();
        }

        return count;
    }

Domain

Subdomains

Frequently Asked Questions

What does size() do?
size() is a function in the netty codebase, defined in common/src/main/java/io/netty/util/internal/InternalThreadLocalMap.java.
Where is size() defined?
size() is defined in common/src/main/java/io/netty/util/internal/InternalThreadLocalMap.java at line 172.

Analyze Your Own Codebase

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

Try Supermodel Free