Home / Function/ _getShort() — netty Function Reference

_getShort() — netty Function Reference

Architecture documentation for the _getShort() function in CompositeByteBuf.java from the netty codebase.

Function java Buffer Telemetry calls 2 called by 2

Entity Profile

Dependency Diagram

graph TD
  33a1aee1_2f1b_da90_e994_f33f127e60a3["_getShort()"]
  6b8e4d93_5aed_4ff7_ccdd_9c021b0fe7d6["CompositeByteBuf"]
  33a1aee1_2f1b_da90_e994_f33f127e60a3 -->|defined in| 6b8e4d93_5aed_4ff7_ccdd_9c021b0fe7d6
  958bb4b4_cce3_9b48_b69f_13c63e6008e5["_getUnsignedMedium()"]
  958bb4b4_cce3_9b48_b69f_13c63e6008e5 -->|calls| 33a1aee1_2f1b_da90_e994_f33f127e60a3
  2bb85f8b_bb4f_2de1_76d8_5043a502596c["_getInt()"]
  2bb85f8b_bb4f_2de1_76d8_5043a502596c -->|calls| 33a1aee1_2f1b_da90_e994_f33f127e60a3
  d3be0b0f_c8ba_dc16_970f_8a5302e005af["idx()"]
  33a1aee1_2f1b_da90_e994_f33f127e60a3 -->|calls| d3be0b0f_c8ba_dc16_970f_8a5302e005af
  43463545_972b_f928_94bd_1067c8bc534c["_getByte()"]
  33a1aee1_2f1b_da90_e994_f33f127e60a3 -->|calls| 43463545_972b_f928_94bd_1067c8bc534c
  style 33a1aee1_2f1b_da90_e994_f33f127e60a3 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

buffer/src/main/java/io/netty/buffer/CompositeByteBuf.java lines 964–974

    @Override
    protected short _getShort(int index) {
        Component c = findComponent0(index);
        if (index + 2 <= c.endOffset) {
            return c.buf.getShort(c.idx(index));
        } else if (order() == ByteOrder.BIG_ENDIAN) {
            return (short) ((_getByte(index) & 0xff) << 8 | _getByte(index + 1) & 0xff);
        } else {
            return (short) (_getByte(index) & 0xff | (_getByte(index + 1) & 0xff) << 8);
        }
    }

Domain

Subdomains

Frequently Asked Questions

What does _getShort() do?
_getShort() is a function in the netty codebase, defined in buffer/src/main/java/io/netty/buffer/CompositeByteBuf.java.
Where is _getShort() defined?
_getShort() is defined in buffer/src/main/java/io/netty/buffer/CompositeByteBuf.java at line 964.
What does _getShort() call?
_getShort() calls 2 function(s): _getByte, idx.
What calls _getShort()?
_getShort() is called by 2 function(s): _getInt, _getUnsignedMedium.

Analyze Your Own Codebase

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

Try Supermodel Free