Home
last modified time | relevance | path

Searched refs:BufferedSink (Results 1 – 25 of 51) sorted by relevance

123

/external/okhttp/okio/okio/src/main/java/okio/
DBufferedSink.java26 public interface BufferedSink extends Sink { interface
30 BufferedSink write(ByteString byteString) throws IOException; in write()
36 BufferedSink write(byte[] source) throws IOException; in write()
42 BufferedSink write(byte[] source, int offset, int byteCount) throws IOException; in write()
51 BufferedSink write(Source source, long byteCount) throws IOException; in write()
54 BufferedSink writeUtf8(String string) throws IOException; in writeUtf8()
60 BufferedSink writeUtf8(String string, int beginIndex, int endIndex) throws IOException; in writeUtf8()
63 BufferedSink writeUtf8CodePoint(int codePoint) throws IOException; in writeUtf8CodePoint()
66 BufferedSink writeString(String string, Charset charset) throws IOException; in writeString()
72 BufferedSink writeString(String string, int beginIndex, int endIndex, Charset charset) in writeString()
[all …]
DRealBufferedSink.java23 final class RealBufferedSink implements BufferedSink {
49 @Override public BufferedSink write(ByteString byteString) throws IOException { in write()
55 @Override public BufferedSink writeUtf8(String string) throws IOException { in writeUtf8()
61 @Override public BufferedSink writeUtf8(String string, int beginIndex, int endIndex) in writeUtf8()
68 @Override public BufferedSink writeUtf8CodePoint(int codePoint) throws IOException { in writeUtf8CodePoint()
74 @Override public BufferedSink writeString(String string, Charset charset) throws IOException { in writeString()
80 @Override public BufferedSink writeString(String string, int beginIndex, int endIndex, in writeString()
87 @Override public BufferedSink write(byte[] source) throws IOException { in write()
93 @Override public BufferedSink write(byte[] source, int offset, int byteCount) throws IOException { in write()
109 @Override public BufferedSink write(Source source, long byteCount) throws IOException { in write()
[all …]
DDeflaterSink.java38 private final BufferedSink sink;
51 DeflaterSink(BufferedSink sink, Deflater deflater) { in DeflaterSink()
/external/okhttp/okio/okio/src/test/java/okio/
DRealBufferedSinkTest.java45 BufferedSink bufferedSink = new RealBufferedSink(sink); in bufferedSinkEmitsTailWhenItIsComplete()
55 BufferedSink bufferedSink = new RealBufferedSink(sink); in bufferedSinkEmitMultipleSegments()
63 BufferedSink bufferedSink = new RealBufferedSink(sink); in bufferedSinkFlush()
73 BufferedSink bufferedSink = new RealBufferedSink(sink); in bytesEmittedToSinkWithFlush()
81 BufferedSink bufferedSink = new RealBufferedSink(sink); in bytesNotEmittedToSinkWithoutFlush()
88 BufferedSink bufferedSink = new RealBufferedSink(sink); in bytesEmittedToSinkWithEmit()
96 BufferedSink bufferedSink = new RealBufferedSink(sink); in completeSegmentsEmitted()
103 BufferedSink bufferedSink = new RealBufferedSink(sink); in incompleteSegmentsNotEmitted()
111 BufferedSink bufferedSink = new RealBufferedSink(mockSink); in closeWithExceptionWhenWriting()
124 BufferedSink bufferedSink = new RealBufferedSink(mockSink); in closeWithExceptionWhenClosing()
[all …]
DBufferedSinkTest.java39 BufferedSink create(Buffer data); in create()
49 @Override public BufferedSink create(Buffer data) { in parameters()
59 @Override public BufferedSink create(Buffer data) { in parameters()
79 private BufferedSink sink;
DOkioTest.java38 BufferedSink sink = Okio.buffer(Okio.sink(file)); in readWriteFile()
52 BufferedSink sink = Okio.buffer(Okio.appendingSink(file)); in appendFile()
/external/okhttp/okhttp/src/main/java/com/squareup/okhttp/
DRequestBody.java22 import okio.BufferedSink;
40 public abstract void writeTo(BufferedSink sink) throws IOException; in writeTo()
70 @Override public void writeTo(BufferedSink sink) throws IOException { in create()
95 @Override public void writeTo(BufferedSink sink) throws IOException {
114 @Override public void writeTo(BufferedSink sink) throws IOException {
DMultipartBuilder.java24 import okio.BufferedSink;
229 private long writeOrCountBytes(BufferedSink sink, boolean countBytes) throws IOException { in writeOrCountBytes()
296 @Override public void writeTo(BufferedSink sink) throws IOException { in writeTo()
/external/okhttp/okhttp-tests/src/test/java/com/squareup/okhttp/
DSocksProxy.java35 import okio.BufferedSink;
101 BufferedSink fromSink = Okio.buffer(Okio.sink(from)); in service()
112 private void hello(BufferedSource fromSource, BufferedSink fromSink) throws IOException { in hello()
141 BufferedSink fromSink) throws IOException { in acceptCommand()
189 BufferedSink toSink = Okio.buffer(Okio.sink(toSocket)); in acceptCommand()
200 final BufferedSource source, final BufferedSink sink) { in transfer()
DMultipartBuilderTest.java20 import okio.BufferedSink;
193 @Override public void writeTo(BufferedSink sink) throws IOException { in streamingPartHasNoLength()
/external/okhttp/okhttp-ws-tests/src/test/java/com/squareup/okhttp/internal/ws/
DWebSocketWriterTest.java23 import okio.BufferedSink;
59 BufferedSink sink = serverWriter.newMessageSink(TEXT); in serverStreamSimpleHello()
72 BufferedSink sink = serverWriter.newMessageSink(TEXT); in serverStreamCloseFlushes()
83 BufferedSink sink = clientWriter.newMessageSink(TEXT); in clientStreamSimpleHello()
132 BufferedSink sink = serverWriter.newMessageSink(BINARY); in serverStreamBinary()
157 BufferedSink sink = clientWriter.newMessageSink(BINARY); in clientStreamBinary()
DRealWebSocketTest.java27 import okio.BufferedSink;
95 BufferedSink sink = client.newMessageSink(TEXT); in streamingMessage()
104 BufferedSink sink = client.newMessageSink(TEXT); in streamingMessageCanInterleavePing()
194 BufferedSink sink = client.newMessageSink(TEXT); in serverCloseWhileWritingThrows()
/external/okhttp/okhttp/src/main/java/com/squareup/okhttp/internal/framed/
DVariant.java19 import okio.BufferedSink;
36 FrameWriter newWriter(BufferedSink sink, boolean client); in newWriter()
DSpdy3.java26 import okio.BufferedSink;
102 @Override public FrameWriter newWriter(BufferedSink sink, boolean client) { in newWriter()
288 private final BufferedSink sink;
290 private final BufferedSink headerBlockOut;
294 Writer(BufferedSink sink, boolean client) { in Writer()
/external/okhttp/samples/guide/src/main/java/com/squareup/okhttp/recipes/
DRequestBodyCompression.java28 import okio.BufferedSink;
92 @Override public void writeTo(BufferedSink sink) throws IOException { in gzip()
93 BufferedSink gzipSink = Okio.buffer(new GzipSink(sink)); in gzip()
DPostStreaming.java24 import okio.BufferedSink;
38 @Override public void writeTo(BufferedSink sink) throws IOException { in run()
/external/okhttp/okhttp-ws/src/main/java/com/squareup/okhttp/ws/
DWebSocket.java20 import okio.BufferedSink;
40 BufferedSink newMessageSink(WebSocket.PayloadType type); in newMessageSink()
DWebSocketCall.java36 import okio.BufferedSink;
161 BufferedSink sink = Internal.instance.connectionRawSink(connection); in createWebSocket()
178 BufferedSink sink, Random random, WebSocketListener listener) { in create()
191 private ConnectionWebSocket(Connection connection, BufferedSource source, BufferedSink sink, in ConnectionWebSocket()
/external/okhttp/okhttp-apache/src/main/java/com/squareup/okhttp/apache/
DHttpEntityBody.java6 import okio.BufferedSink;
38 @Override public void writeTo(BufferedSink sink) throws IOException { in writeTo()
/external/okhttp/mockwebserver/src/main/java/com/squareup/okhttp/internal/framed/
DFramedServer.java34 import okio.BufferedSink;
129 BufferedSink out = Okio.buffer(stream.getSink()); in send404()
141 BufferedSink out = Okio.buffer(stream.getSink()); in serveDirectory()
158 BufferedSink out = Okio.buffer(stream.getSink()); in serveFile()
/external/okhttp/okhttp-ws/src/main/java/com/squareup/okhttp/internal/ws/
DRealWebSocket.java26 import okio.BufferedSink;
46 public RealWebSocket(boolean isClient, BufferedSource source, BufferedSink sink, Random random, in RealWebSocket()
103 @Override public BufferedSink newMessageSink(PayloadType type) { in newMessageSink()
DWebSocketWriter.java21 import okio.BufferedSink;
53 private final BufferedSink sink;
64 public WebSocketWriter(boolean isClient, BufferedSink sink, Random random) { in WebSocketWriter()
158 public BufferedSink newMessageSink(PayloadType type) { in newMessageSink()
/external/okhttp/okio/
DCHANGELOG.md34 * New: `BufferedSink` can now write substrings directly, potentially saving an
43 `BufferedSource` and `BufferedSink`. Unlike the alternatives, these methods
76 * New APIs: `BufferedSink.emit()`, `BufferedSource.request()` and `BufferedSink.indexOfElement()`.
/external/okhttp/okhttp/src/main/java/com/squareup/okhttp/internal/
DInternal.java36 import okio.BufferedSink;
99 public abstract BufferedSink connectionRawSink(Connection connection); in connectionRawSink()
/external/okhttp/mockwebserver/src/main/java/com/squareup/okhttp/mockwebserver/
DMockWebServer.java74 import okio.BufferedSink;
477 BufferedSink sink = Okio.buffer(Okio.sink(socket));
501 BufferedSink sink = Okio.buffer(Okio.sink(raw));
515 private boolean processOneRequest(Socket socket, BufferedSource source, BufferedSink sink)
586 private RecordedRequest readRequest(Socket socket, BufferedSource source, BufferedSink sink,
656 private void handleWebSocketUpgrade(Socket socket, BufferedSource source, BufferedSink sink,
711 private void writeHttpResponse(Socket socket, BufferedSink sink, MockResponse response)
749 BufferedSink sink, long byteCount, boolean isRequest) throws IOException {
930 BufferedSink sink = Okio.buffer(stream.getSink());

123