| Package | Description |
|---|---|
| org.aoju.bus.core.io | |
| org.aoju.bus.core.utils | |
| org.aoju.bus.http.cache | |
| org.aoju.bus.http.metric.http |
| Modifier and Type | Interface and Description |
|---|---|
interface |
BufferSink
一种接收器,它在内部保存缓冲区,
以便调用者可以进行小的写操作没有性能损失
|
| Modifier and Type | Class and Description |
|---|---|
class |
Buffer
内存中字节的集合.
|
class |
DeflaterSink
这种流体的强冲刷可能导致压缩降低 每一个
调用
DeflaterSink.flush()立即压缩所有当前缓存的数据;
这种早期压缩可能不如执行的压缩有效 |
class |
DelegateSink
将调用转发给另一个调用的
Sink |
class |
FaultHideSink
不会抛出IOExceptions的接收器,
即使底层接收器抛出了IOExceptions
|
class |
GzipSink
这相当于使用
Deflater同步刷新选项
该类不提供任何部分刷新机制 为获得最佳性能,
只在应用程序行为需要时调用GzipSink.flush() |
class |
HashSink
一个接收器,计算它接受的全部字节流的哈希值 若要使用,请创建
使用您首选的哈希算法实例 将所有数据写入接收器,然后调用
HashSink.hash()来计算最终的哈希值 |
class |
RealSink |
| Modifier and Type | Field and Description |
|---|---|
Sink |
RealSink.sink |
| Modifier and Type | Method and Description |
|---|---|
Sink |
FileSystem.appendingSink(File file) |
Sink |
DelegateSink.delegate() |
Sink |
Pipe.sink() |
Sink |
FileSystem.sink(File file) |
Sink |
AsyncTimeout.sink(Sink sink)
|
| Modifier and Type | Method and Description |
|---|---|
static HashSink |
HashSink.hmacSha1(Sink sink,
ByteString key) |
static HashSink |
HashSink.hmacSha256(Sink sink,
ByteString key) |
static HashSink |
HashSink.hmacSha512(Sink sink,
ByteString key) |
static HashSink |
HashSink.md5(Sink sink) |
long |
RealSource.readAll(Sink sink) |
long |
BufferSource.readAll(Sink sink)
Removes all bytes from this and appends them to
sink. |
long |
Buffer.readAll(Sink sink) |
static HashSink |
HashSink.sha1(Sink sink) |
static HashSink |
HashSink.sha256(Sink sink) |
static HashSink |
HashSink.sha512(Sink sink) |
Sink |
AsyncTimeout.sink(Sink sink)
|
| Constructor and Description |
|---|
DeflaterSink(Sink sink,
Deflater deflater) |
DelegateSink(Sink delegate) |
FaultHideSink(Sink delegate) |
GzipSink(Sink sink) |
RealSink(Sink sink) |
| Modifier and Type | Method and Description |
|---|---|
static Sink |
IoUtils.appendingSink(File file)
返回一个附加到
file的接收器 |
static Sink |
IoUtils.blackhole()
返回一个都不写的接收器
|
static Sink |
IoUtils.sink(File file)
返回一个向
file写入的接收器 |
static Sink |
IoUtils.sink(OutputStream out)
返回一个向
out写入的接收器 |
static Sink |
IoUtils.sink(Path path,
OpenOption... options)
返回一个向
path写入的接收器. |
static Sink |
IoUtils.sink(Socket socket)
返回一个向
socket写入的接收器。优先选择这个方法,
而不是IoUtils.sink(OutputStream),因为这个方法支持超时
当套接字写超时时,套接字将由任务线程异步关闭 |
| Modifier and Type | Method and Description |
|---|---|
static BufferSink |
IoUtils.buffer(Sink sink)
返回一个新接收器,该接收器缓冲写
sink
返回的接收器将批量写入sink |
| Modifier and Type | Method and Description |
|---|---|
Sink |
CacheRequest.body() |
Sink |
DiskLruCache.Editor.newSink(int index) |
| Modifier and Type | Method and Description |
|---|---|
Sink |
HttpCodec.createRequestBody(Request request,
long contentLength)
返回一个可以对请求体进行流处理的输出流.
|
Sink |
Http2Codec.createRequestBody(Request request,
long contentLength) |
Sink |
Http1Codec.createRequestBody(Request request,
long contentLength) |
Sink |
Http2Stream.getSink() |
Sink |
Http1Codec.newChunkedSink() |
Sink |
Http1Codec.newFixedLengthSink(long contentLength) |
Copyright © 2020. All rights reserved.