Sample

int-7ada9b3396be-I10

Remove about 40% of line-break groups while retaining structure

Matched original source

Lines26

Scores

MethodScoreScale
Posnett0.60–1; higher is more readable
Scalabrino0.8380–1; higher is more readable
Dorn0.6840–1; higher is more readable
Mi0.0440–1; higher is more readable
LLOC1Logical lines; fewer is more readable
DeepSeek V4 Pro140–20; mean of three runs
GPT-6.1 Sol16.330–20; mean of three runs
BTTF0.6940–1; higher is more readable

Views

Source code

package org.springframework.test.web.reactive.server; import org.jspecify.annotations.Nullable; import org.springframework.http.client.reactive.ClientHttpConnector; import org.springframework.web.server.adapter.WebHttpHandlerBuilder; /** * Contract to encapsulate customizations to a {@link WebTestClient.Builder}. * Typically used by frameworks that wish to provide a shortcut for common * initialization. * * @author Rossen Stoyanchev * @since 5.0 * @see MockServerConfigurer */ public interface WebTestClientConfigurer { /** * Use methods on {@link WebTestClient.Builder} to modify test client * settings. For a mock WebFlux server, use {@link WebHttpHandlerBuilder} * to customize server configuration. For a MockMvc server, mutate the * {@link org.springframework.test.web.servlet.client.MockMvcHttpConnector} * and set it on {@link WebTestClient.Builder}. * @param builder the WebTestClient builder for test client changes * @param httpHandlerBuilder for mock WebFlux server settings * @param connector the connector in use */ void afterConfigurerAdded(WebTestClient.Builder builder, @Nullable WebHttpHandlerBuilder httpHandlerBuilder, @Nullable ClientHttpConnector connector); }

Loading feature diagnosis…

Source regions

Feature contributions

Feature contributions

FeatureValueContribution
(log-odds)
Halstead volumeHow much symbolic information the code contains. It combines the total number of operators and values with the number of distinct ones.353.108−11.653
Source linesThe number of non-empty source lines.26+10.4
Byte entropyHow varied the bytes in the source text are. Repeated bytes give a lower value; a more even mixture gives a higher value.4.807−7.21

Intercept 8.87 + feature contributions = 0.407 (log-odds).
Score = sigmoid(0.407) = 0.6.

Score0.838

Feature contributions

FeatureValueContribution
(log-odds)
Identifier layout (horizontal)How rapidly the visual pattern of identifier characters changes from left to right. It measures spatial frequency, not the meaning of the names.109.926−0.991
Comment layout (horizontal)How rapidly the visual pattern of comment characters changes from left to right.110+0.97
Operator visual areaThe share of the code’s visual area occupied by operators such as +, =, and *.0.026+0.685
Indentation frequencyHow rapidly indentation changes from line to line.9−0.426
Number layout frequencyHow rapidly the number of numeric values per line changes through the code.1+0.398
Comment layout frequencyHow frequently the layout switches between lines containing only comments or whitespace and lines containing code.26+0.116
Identifier layout (vertical)How rapidly the visual pattern of identifier characters changes from top to bottom.25.694−0.051

Intercept 0.07 + feature contributions = 0.772 (log-odds).
Score = sigmoid(0.772) = 0.684.

Score0.044
Score1
Run 1

The code is generally clear and well-organized, with a single-purpose interface and useful Javadoc. However, readability is impaired by formatting issues: multiple imports and parts of the Javadoc/interface are cramped onto single lines, and the closing brace shares a line with the method signature. The method signature is moderately complex with three parameters, but acceptable. The Javadoc clearly explains intent and usage, and action granularity is appropriate despite line compression. Overall structure is logical, nesting is nonexistent, and reading flow would improve with standard line breaks and import separation.

Run 2

The code is a Spring interface with clear Javadoc, but readability suffers from formatting issues. Import statements are collapsed onto a few lines, and the interface declaration is placed on the same line as the closing Javadoc comment, breaking visual separation. The method signature spans three lines with awkward indentation, and the closing brace is placed on the same line as the last parameter, making the structure harder to scan. While the logic is simple and intent is clear from documentation, the poor spacing and inconsistent line breaks reduce readability. Following standard formatting conventions would improve the score significantly.

Run 3

The code is generally readable but has structural issues. The interface has a clear purpose with good Javadoc, but formatting is inconsistent: multiple imports on one line, a closing brace and comment placed awkwardly at the end of the interface declaration, and parameter alignment that doesn't follow typical Java conventions. The method signature spans multiple lines with inconsistent indentation, slightly hurting readability. The nesting is flat and variable names are clear, but the layout disrupts natural reading flow. Overall, the logic is simple and understandable, but the formatting choices reduce clarity and make the code appear less polished than it could be.

Run 1

Code Structure: A small, logically organized interface with relevant imports and thorough documentation, though compressed formatting weakens separation. Nesting: Minimal nesting makes the declaration easy to follow. Clarity of intent: Descriptive names, parameter documentation, and nullable annotations clearly communicate the customization contract. Code length: Concise implementation with proportionate documentation. Action granularity: Two imports share a line, and the closing interface brace shares the method declaration line, reducing visual clarity. Reading flow: Documentation naturally leads into the method, but placing the interface declaration immediately after the Javadoc terminator and compressing the final parameter and closing brace interrupts scanning.

Run 2

Code Structure: A logically organized interface with imports, documentation, and a single method, though compressed formatting weakens separation. Nesting: Minimal nesting makes it easy to follow. Clarity of intent: Descriptive names, nullability annotations, and detailed Javadoc clearly explain the customization contract and parameters. Code length: Appropriately concise for a small interface; documentation provides useful context. Action granularity: Two imports share a line, and closing documentation and interface braces share lines with declarations, reducing visual clarity. Reading flow: The sequence is natural, but crowded imports, the interface declaration immediately following the Javadoc terminator, and the closing brace on the method line interrupt otherwise readable formatting.

Run 3

Code Structure: The package, imports, interface documentation, and single method follow a logical organization, but compressed formatting weakens separation. Nesting: Minimal nesting makes the declaration easy to understand. Clarity of intent: Descriptive names, nullable annotations, and detailed Javadoc clearly explain the configuration hook and its parameters. Code length: Appropriately concise for a single-method interface; documentation provides useful context. Action granularity: Two imports share a line, and closing comments and braces share lines with declarations, reducing visual clarity. Reading flow: The overall sequence is natural, but crowded imports, the interface declaration immediately after the Javadoc closing delimiter, and the final brace attached to the method signature interrupt scanning.