Home / Function/ verifyStandardSetting() — netty Function Reference

verifyStandardSetting() — netty Function Reference

Architecture documentation for the verifyStandardSetting() function in Http2Settings.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  45e0960d_5524_ce9c_6865_4f64e8437171["verifyStandardSetting()"]
  0bc654ce_e607_2ea6_4098_4fbeb4bbc9c9["Http2Settings"]
  45e0960d_5524_ce9c_6865_4f64e8437171 -->|defined in| 0bc654ce_e607_2ea6_4098_4fbeb4bbc9c9
  8cdc8938_3e13_a07b_dd11_88cf608f6fb1["Long()"]
  8cdc8938_3e13_a07b_dd11_88cf608f6fb1 -->|calls| 45e0960d_5524_ce9c_6865_4f64e8437171
  style 45e0960d_5524_ce9c_6865_4f64e8437171 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

codec-http2/src/main/java/io/netty/handler/codec/http2/Http2Settings.java lines 227–280

    private static void verifyStandardSetting(int key, Long value) {
        checkNotNull(value, "value");
        switch (key) {
            case SETTINGS_HEADER_TABLE_SIZE:
                if (value < MIN_HEADER_TABLE_SIZE || value > MAX_HEADER_TABLE_SIZE) {
                    throw new IllegalArgumentException("Setting HEADER_TABLE_SIZE is invalid: " + value +
                            ", expected [" + MIN_HEADER_TABLE_SIZE + ", " + MAX_HEADER_TABLE_SIZE + ']');
                }
                break;
            case SETTINGS_ENABLE_PUSH:
                if (value != 0L && value != 1L) {
                    throw new IllegalArgumentException("Setting ENABLE_PUSH is invalid: " + value +
                            ", expected [0, 1]");
                }
                break;
            case SETTINGS_MAX_CONCURRENT_STREAMS:
                if (value < MIN_CONCURRENT_STREAMS || value > MAX_CONCURRENT_STREAMS) {
                    throw new IllegalArgumentException("Setting MAX_CONCURRENT_STREAMS is invalid: " + value +
                            ", expected [" + MIN_CONCURRENT_STREAMS + ", " + MAX_CONCURRENT_STREAMS + ']');
                }
                break;
            case SETTINGS_INITIAL_WINDOW_SIZE:
                if (value < MIN_INITIAL_WINDOW_SIZE || value > MAX_INITIAL_WINDOW_SIZE) {
                    throw new IllegalArgumentException("Setting INITIAL_WINDOW_SIZE is invalid: " + value +
                            ", expected [" + MIN_INITIAL_WINDOW_SIZE + ", " + MAX_INITIAL_WINDOW_SIZE + ']');
                }
                break;
            case SETTINGS_MAX_FRAME_SIZE:
                if (!isMaxFrameSizeValid(value.intValue())) {
                    throw new IllegalArgumentException("Setting MAX_FRAME_SIZE is invalid: " + value +
                            ", expected [" + MAX_FRAME_SIZE_LOWER_BOUND + ", " + MAX_FRAME_SIZE_UPPER_BOUND + ']');
                }
                break;
            case SETTINGS_MAX_HEADER_LIST_SIZE:
                if (value < MIN_HEADER_LIST_SIZE || value > MAX_HEADER_LIST_SIZE) {
                    throw new IllegalArgumentException("Setting MAX_HEADER_LIST_SIZE is invalid: " + value +
                            ", expected [" + MIN_HEADER_LIST_SIZE + ", " + MAX_HEADER_LIST_SIZE + ']');
                }
                break;
            case SETTINGS_ENABLE_CONNECT_PROTOCOL:
                if (value != 0L && value != 1L) {
                    throw new IllegalArgumentException("Setting ENABLE_CONNECT_PROTOCOL is invalid: " + value +
                            ", expected [0, 1]");
                }
                break;
            default:
                // Non-standard HTTP/2 setting
                if (value < 0 || value > MAX_UNSIGNED_INT) {
                    throw new IllegalArgumentException("Non-standard setting 0x" + toHexString(key) + " is invalid: " +
                            value + ", expected unsigned 32-bit value");
                }
                break;
        }
    }

Domain

Subdomains

Called By

Frequently Asked Questions

What does verifyStandardSetting() do?
verifyStandardSetting() is a function in the netty codebase, defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2Settings.java.
Where is verifyStandardSetting() defined?
verifyStandardSetting() is defined in codec-http2/src/main/java/io/netty/handler/codec/http2/Http2Settings.java at line 227.
What calls verifyStandardSetting()?
verifyStandardSetting() is called by 1 function(s): Long.

Analyze Your Own Codebase

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

Try Supermodel Free