writeBits() — netty Function Reference
Architecture documentation for the writeBits() function in Bzip2BitWriter.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD 0786eee7_4e0c_3f4f_870d_2f59e7bdce79["writeBits()"] 31f32361_6352_65c5_783c_9a4bef96677a["Bzip2BitWriter"] 0786eee7_4e0c_3f4f_870d_2f59e7bdce79 -->|defined in| 31f32361_6352_65c5_783c_9a4bef96677a 1f89857b_deb5_14dc_2930_fb3b01467626["writeInt()"] 1f89857b_deb5_14dc_2930_fb3b01467626 -->|calls| 0786eee7_4e0c_3f4f_870d_2f59e7bdce79 1f89857b_deb5_14dc_2930_fb3b01467626["writeInt()"] 0786eee7_4e0c_3f4f_870d_2f59e7bdce79 -->|calls| 1f89857b_deb5_14dc_2930_fb3b01467626 style 0786eee7_4e0c_3f4f_870d_2f59e7bdce79 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-compression/src/main/java/io/netty/handler/codec/compression/Bzip2BitWriter.java lines 41–56
void writeBits(ByteBuf out, final int count, final long value) {
if (count < 0 || count > 32) {
throw new IllegalArgumentException("count: " + count + " (expected: 0-32)");
}
int bitCount = this.bitCount;
long bitBuffer = this.bitBuffer | value << 64 - count >>> bitCount;
bitCount += count;
if (bitCount >= 32) {
out.writeInt((int) (bitBuffer >>> 32));
bitBuffer <<= 32;
bitCount -= 32;
}
this.bitBuffer = bitBuffer;
this.bitCount = bitCount;
}
Domain
Subdomains
Calls
Called By
Source
Frequently Asked Questions
What does writeBits() do?
writeBits() is a function in the netty codebase, defined in codec-compression/src/main/java/io/netty/handler/codec/compression/Bzip2BitWriter.java.
Where is writeBits() defined?
writeBits() is defined in codec-compression/src/main/java/io/netty/handler/codec/compression/Bzip2BitWriter.java at line 41.
What does writeBits() call?
writeBits() calls 1 function(s): writeInt.
What calls writeBits()?
writeBits() is called by 1 function(s): writeInt.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free