MCPcopy Create free account
hub / github.com/apache/tomcat / Http11InputBuffer

Class Http11InputBuffer

java/org/apache/coyote/http11/Http11InputBuffer.java:42–888  ·  view source on GitHub ↗

InputBuffer for HTTP that provides request header parsing as well as transfer encoding.

Source from the content-addressed store, hash-verified

40 * InputBuffer for HTTP that provides request header parsing as well as transfer encoding.
41 */
42public class Http11InputBuffer implements InputBuffer, ApplicationBufferHandler, HeaderDataSource {
43
44 // -------------------------------------------------------------- Constants
45
46 private static final Log log = LogFactory.getLog(Http11InputBuffer.class);
47
48 /**
49 * The string manager for this package.
50 */
51 private static final StringManager sm = StringManager.getManager(Http11InputBuffer.class);
52
53
54 private static final byte[] CLIENT_PREFACE_START =
55 "PRI * HTTP/2.0\r\n\r\nSM\r\n\r\n".getBytes(StandardCharsets.ISO_8859_1);
56
57 /**
58 * Associated Coyote request.
59 */
60 private final Request request;
61
62
63 /**
64 * State.
65 */
66 private volatile boolean parsingHeader;
67
68
69 /**
70 * Swallow input ? (in the case of an expectation)
71 */
72 private boolean swallowInput;
73
74
75 /**
76 * The read buffer.
77 */
78 private ByteBuffer byteBuffer;
79
80
81 /**
82 * Pos of the end of the header in the buffer, which is also the start of the body.
83 */
84 private int end;
85
86
87 /**
88 * Wrapper that provides access to the underlying socket.
89 */
90 private SocketWrapperBase<?> wrapper;
91
92
93 /**
94 * Underlying input buffer.
95 */
96 private final InputBuffer inputStreamInputBuffer;
97
98
99 /**

Callers

nothing calls this directly

Calls 3

getLogMethod · 0.95
getManagerMethod · 0.95
getBytesMethod · 0.45

Tested by

no test coverage detected