Search Options

Results per page
Sort
Preferred Languages
Advance

Results 1 - 2 of 2 for prefixMask (0.05 sec)

  1. okhttp/src/main/kotlin/okhttp3/internal/http2/Hpack.kt

          fun readInt(
            firstByte: Int,
            prefixMask: Int,
          ): Int {
            val prefix = firstByte and prefixMask
            if (prefix < prefixMask) {
              return prefix // This was a single byte value.
            }
    
            // This is a multibyte value. Read 7 bits at a time.
            var result = prefixMask
            var shift = 0
            while (true) {
              val b = readByte()
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 22.5K bytes
    - Viewed (0)
  2. okhttp/src/test/java/okhttp3/internal/http2/HpackTest.kt

        assertBytes(31, 224, 255, 255, 255, 7)
        assertThat(newReader(byteStream(224, 255, 255, 255, 7)).readInt(31, 31))
          .isEqualTo(0x7fffffff)
      }
    
      @Test
      fun prefixMask() {
        hpackWriter!!.writeInt(31, 31, 0)
        assertBytes(31, 0)
        assertThat(newReader(byteStream(0)).readInt(31, 31)).isEqualTo(31)
      }
    
      @Test
      fun prefixMaskMinusOne() {
    Registered: Fri Nov 01 11:42:11 UTC 2024
    - Last Modified: Mon Jan 08 01:13:22 UTC 2024
    - 38.2K bytes
    - Viewed (0)
Back to top