comparison src/org/eclipse/jetty/io/EndPoint.java @ 1048:2b769da7f67d

remove Buffer
author Franklin Schmidt <fschmidt@gmail.com>
date Mon, 07 Nov 2016 23:15:42 -0700
parents bdb6eb0fbf93
children ebb0f1343ef6
comparison
equal deleted inserted replaced
1047:1accf965d51a 1048:2b769da7f67d
53 * The buffer may chose to do a compact before filling. 53 * The buffer may chose to do a compact before filling.
54 * @return an <code>int</code> value indicating the number of bytes 54 * @return an <code>int</code> value indicating the number of bytes
55 * filled or -1 if EOF is reached. 55 * filled or -1 if EOF is reached.
56 * @throws EofException If input is shutdown or the endpoint is closed. 56 * @throws EofException If input is shutdown or the endpoint is closed.
57 */ 57 */
58 int fill(Buffer buffer) throws IOException; 58 int fill(JBuffer buffer) throws IOException;
59 59
60 60
61 /** 61 /**
62 * Flush the buffer from the current getIndex to it's putIndex using whatever byte 62 * Flush the buffer from the current getIndex to it's putIndex using whatever byte
63 * sink is backing the buffer. The getIndex is updated with the number of bytes flushed. 63 * sink is backing the buffer. The getIndex is updated with the number of bytes flushed.
66 * 66 *
67 * @param buffer The buffer to flush. This buffers getIndex is updated. 67 * @param buffer The buffer to flush. This buffers getIndex is updated.
68 * @return the number of bytes written 68 * @return the number of bytes written
69 * @throws EofException If the endpoint is closed or output is shutdown. 69 * @throws EofException If the endpoint is closed or output is shutdown.
70 */ 70 */
71 int flush(Buffer buffer) throws IOException; 71 int flush(JBuffer buffer) throws IOException;
72 72
73 /** 73 /**
74 * Flush the buffer from the current getIndex to it's putIndex using whatever byte 74 * Flush the buffer from the current getIndex to it's putIndex using whatever byte
75 * sink is backing the buffer. The getIndex is updated with the number of bytes flushed. 75 * sink is backing the buffer. The getIndex is updated with the number of bytes flushed.
76 * Any mark set is cleared. 76 * Any mark set is cleared.
81 * @param header A buffer to write before flushing this buffer. This buffers getIndex is updated. 81 * @param header A buffer to write before flushing this buffer. This buffers getIndex is updated.
82 * @param buffer The buffer to flush. This buffers getIndex is updated. 82 * @param buffer The buffer to flush. This buffers getIndex is updated.
83 * @param trailer A buffer to write after flushing this buffer. This buffers getIndex is updated. 83 * @param trailer A buffer to write after flushing this buffer. This buffers getIndex is updated.
84 * @return the total number of bytes written. 84 * @return the total number of bytes written.
85 */ 85 */
86 int flush(Buffer header, Buffer buffer, Buffer trailer) throws IOException; 86 int flush(JBuffer header, JBuffer buffer, JBuffer trailer) throws IOException;
87 87
88 88
89 /* ------------------------------------------------------------ */ 89 /* ------------------------------------------------------------ */
90 /** 90 /**
91 * @return The local IP address to which this <code>EndPoint</code> is bound, or <code>null</code> 91 * @return The local IP address to which this <code>EndPoint</code> is bound, or <code>null</code>