public class SseEmitterHandler extends Object
| 构造器和说明 |
|---|
SseEmitterHandler(SseEmitter emitter) |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
complete()
完成(用于手动控制)
|
void |
send(SseEvent event)
发送事件内容
|
void |
start()
开始
|
protected void |
stop()
停止
|
protected void |
stopOnError(Throwable e)
因出错停目
|
protected void |
stopOnTimeout()
因操时停止(异步操时)
|
public SseEmitterHandler(SseEmitter emitter)
public void send(SseEvent event) throws IOException
event - 事件数据IOExceptionpublic void complete()
throws IOException
IOExceptionprotected void stopOnError(Throwable e) throws IOException
IOExceptionprotected void stopOnTimeout()
throws IOException
IOExceptionprotected void stop()
throws IOException
IOExceptionCopyright © 2024. All rights reserved.