testGetBrTargetContentEncoding() — netty Function Reference
Architecture documentation for the testGetBrTargetContentEncoding() function in HttpContentCompressorOptionsTest.java from the netty codebase.
Entity Profile
Dependency Diagram
graph TD ec37ab5b_d889_3a1d_8328_56b62d188190["testGetBrTargetContentEncoding()"] 7ae1f39f_149e_c84a_ee2f_a6350639bfd3["HttpContentCompressorOptionsTest"] ec37ab5b_d889_3a1d_8328_56b62d188190 -->|defined in| 7ae1f39f_149e_c84a_ee2f_a6350639bfd3 style ec37ab5b_d889_3a1d_8328_56b62d188190 fill:#6366f1,stroke:#818cf8,color:#fff
Relationship Graph
Source Code
codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorOptionsTest.java lines 38–64
@Test
void testGetBrTargetContentEncoding() {
HttpContentCompressor compressor = new HttpContentCompressor(
StandardCompressionOptions.gzip(),
StandardCompressionOptions.deflate(),
StandardCompressionOptions.brotli(),
StandardCompressionOptions.zstd(),
StandardCompressionOptions.snappy()
);
String[] tests = {
// Accept-Encoding -> Content-Encoding
"", null,
"*", "br",
"*;q=0.0", null,
"br", "br",
"compress, br;q=0.5", "br",
"br; q=0.5, identity", "br",
"br; q=0, deflate", "br",
};
for (int i = 0; i < tests.length; i += 2) {
String acceptEncoding = tests[i];
String contentEncoding = tests[i + 1];
String targetEncoding = compressor.determineEncoding(acceptEncoding);
assertEquals(contentEncoding, targetEncoding);
}
}
Domain
Subdomains
Defined In
Source
Frequently Asked Questions
What does testGetBrTargetContentEncoding() do?
testGetBrTargetContentEncoding() is a function in the netty codebase, defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorOptionsTest.java.
Where is testGetBrTargetContentEncoding() defined?
testGetBrTargetContentEncoding() is defined in codec-http/src/test/java/io/netty/handler/codec/http/HttpContentCompressorOptionsTest.java at line 38.
Analyze Your Own Codebase
Get architecture documentation, dependency graphs, and domain analysis for your codebase in minutes.
Try Supermodel Free