Home / Function/ hashCodeAsciiSanitizeInt() — netty Function Reference

hashCodeAsciiSanitizeInt() — netty Function Reference

Architecture documentation for the hashCodeAsciiSanitizeInt() function in PlatformDependent.java from the netty codebase.

Entity Profile

Dependency Diagram

graph TD
  9d9d4099_3d66_e9a1_9fd8_9e3cf98c9a12["hashCodeAsciiSanitizeInt()"]
  2e66d079_807f_6785_864f_73ab09fbc515["PlatformDependent"]
  9d9d4099_3d66_e9a1_9fd8_9e3cf98c9a12 -->|defined in| 2e66d079_807f_6785_864f_73ab09fbc515
  8a8c01b2_2927_ec9a_df31_d52673d17a1e["hashCodeAsciiCompute()"]
  8a8c01b2_2927_ec9a_df31_d52673d17a1e -->|calls| 9d9d4099_3d66_e9a1_9fd8_9e3cf98c9a12
  3af1bd26_c77c_d99a_9035_8e53792f0908["hashCodeAscii()"]
  3af1bd26_c77c_d99a_9035_8e53792f0908 -->|calls| 9d9d4099_3d66_e9a1_9fd8_9e3cf98c9a12
  style 9d9d4099_3d66_e9a1_9fd8_9e3cf98c9a12 fill:#6366f1,stroke:#818cf8,color:#fff

Relationship Graph

Source Code

common/src/main/java/io/netty/util/internal/PlatformDependent.java lines 861–873

    private static int hashCodeAsciiSanitizeInt(CharSequence value, int offset) {
        if (BIG_ENDIAN_NATIVE_ORDER) {
            // mimic a unsafe.getInt call on a big endian machine
            return (value.charAt(offset + 3) & 0x1f) |
                   (value.charAt(offset + 2) & 0x1f) << 8 |
                   (value.charAt(offset + 1) & 0x1f) << 16 |
                   (value.charAt(offset) & 0x1f) << 24;
        }
        return (value.charAt(offset + 3) & 0x1f) << 24 |
               (value.charAt(offset + 2) & 0x1f) << 16 |
               (value.charAt(offset + 1) & 0x1f) << 8 |
               (value.charAt(offset) & 0x1f);
    }

Domain

Subdomains

Frequently Asked Questions

What does hashCodeAsciiSanitizeInt() do?
hashCodeAsciiSanitizeInt() is a function in the netty codebase, defined in common/src/main/java/io/netty/util/internal/PlatformDependent.java.
Where is hashCodeAsciiSanitizeInt() defined?
hashCodeAsciiSanitizeInt() is defined in common/src/main/java/io/netty/util/internal/PlatformDependent.java at line 861.
What calls hashCodeAsciiSanitizeInt()?
hashCodeAsciiSanitizeInt() is called by 2 function(s): hashCodeAscii, hashCodeAsciiCompute.

Analyze Your Own Codebase

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

Try Supermodel Free