T - このイベントに含まれるデータの型 public static interface ServerSentEvent.Builder<T>SseEvent の変更可能なビルダー。| 修飾子と型 | メソッドと説明 |
|---|---|
ServerSentEvent<T> | build() イベントを作成します。 |
ServerSentEvent.Builder<T> | comment(StringSE comment)SSE コメントを設定します。 |
ServerSentEvent.Builder<T> | data(T data)data フィールドの値を設定します。 |
ServerSentEvent.Builder<T> | event(StringSE event)event フィールドの値を設定します。 |
ServerSentEvent.Builder<T> | id(StringSE id)id フィールドの値を設定します。 |
ServerSentEvent.Builder<T> | retry(DurationSE retry)retry フィールドの値を設定します。 |
ServerSentEvent.Builder<T> id(StringSE id)
id フィールドの値を設定します。id - id フィールドの値 this ビルダー ServerSentEvent.Builder<T> event(StringSE event)
event フィールドの値を設定します。event - イベントフィールドの値 this ビルダー ServerSentEvent.Builder<T> retry(DurationSE retry)
retry フィールドの値を設定します。retry - 再試行フィールドの値 this ビルダー ServerSentEvent.Builder<T> comment(StringSE comment)
comment - 設定するコメント this ビルダー ServerSentEvent.Builder<T> data(@Nullable T data)
data フィールドの値を設定します。data 引数が複数行の String である場合、Server-Sent Events W3C 勧告で定義されているように、複数の data フィールド行に変換されます。data が文字列でない場合は、JSON にエンコードされます。data - データフィールドの値 this ビルダー ServerSentEvent<T> build()