クラスの使用
org.springframework.web.reactive.socket.CloseStatus
CloseStatus を使用するパッケージ
パッケージ
説明
リアクティブ WebSocket 相互作用の抽象化とサポートクラス。
Spring の Reactive WebSocket API を WebSocket ランタイムとの間で適合させるクラス。
org.springframework.web.reactive.socket 内の CloseStatus 使用
CloseStatus として宣言されている org.springframework.web.reactive.socket のフィールド修飾子と型フィールド説明static final CloseStatusCloseStatus.BAD_DATA「1007 は、メッセージの型と一致しないメッセージ内のデータ(たとえば、テキストメッセージ内の非 UTF-8 [RFC3629] データ)を受信したため、エンドポイントが接続を終了していることを示します。」static final CloseStatusCloseStatus.GOING_AWAY「1001 は、サーバーがダウンしたり、ブラウザーがページから移動したりするなど、エンドポイントが「離れる」ことを示します。static final CloseStatusCloseStatus.NO_CLOSE_FRAME「1006 は予約済みの値であり、エンドポイントによって Close コントロールフレームのステータスコードとして設定してはなりません(MUST NOT)。static final CloseStatusCloseStatus.NO_STATUS_CODE「1005 は予約済みの値であり、エンドポイントによって Close コントロールフレームのステータスコードとして設定してはなりません(MUST NOT)。static final CloseStatusCloseStatus.NORMAL「1000 は通常の閉鎖を示します。つまり、接続が確立された目的が達成されたことを意味します。」static final CloseStatusCloseStatus.NOT_ACCEPTABLE「1003 は、エンドポイントが受信できない型のデータを受信したため、エンドポイントが接続を終了していることを示します(たとえば、テキストデータのみを理解するエンドポイントは、バイナリメッセージを受信した場合にこれを送信できます)。」static final CloseStatusCloseStatus.POLICY_VIOLATION「1008 は、ポリシーに違反するメッセージを受信したため、エンドポイントが接続を終了していることを示します。static final CloseStatusCloseStatus.PROTOCOL_ERROR「1002 は、プロトコルエラーが原因でエンドポイントが接続を終了していることを示します。」static final CloseStatusCloseStatus.REQUIRED_EXTENSION「1010 は、サーバーが 1 つ以上の内線をネゴシエートすることを期待していたが、サーバーが WebSocket ハンドシェイクのレスポンスメッセージで返さなかったため、エンドポイント(クライアント)が接続を終了していることを示します。static final CloseStatusCloseStatus.SERVER_ERROR「1011 は、サーバーがリクエストの実行を妨げる予期しない状況が発生したため、サーバーが接続を終了していることを示しています。」static final CloseStatusCloseStatus.SERVICE_OVERLOAD「1013 は、サービスがオーバーロードになっていることを示します。static final CloseStatusCloseStatus.SERVICE_RESTARTED「1012 は、サービスが再起動されることを示します。static final CloseStatusCloseStatus.TLS_HANDSHAKE_FAILURE「1015 は予約済みの値であり、エンドポイントによって Close コントロールフレームのステータスコードとして設定してはなりません(MUST NOT)。static final CloseStatusCloseStatus.TOO_BIG_TO_PROCESS「1009 は、処理するには大きすぎるメッセージを受信したため、エンドポイントが接続を終了していることを示します。」修飾子と型メソッド説明static CloseStatus指定されたコードの定数を返すか、コードが一致しないか理由がある場合は新しいインスタンスを作成します。CloseStatus.withReason(StringSE reason) 指定された理由で、このCloseStatusから新しいCloseStatusを作成します。型 CloseStatus の引数を持つ型を返す org.springframework.web.reactive.socket のメソッド修飾子と型メソッド説明reactor.core.publisher.Mono<CloseStatus>WebSocketSession.closeStatus()セッションがローカルまたはリモートで閉じられるCloseStatusへのアクセスを提供します。セッションがステータスなしで終了した場合は、空になります。型 CloseStatus のパラメーターを持つ org.springframework.web.reactive.socket のメソッド修飾子と型メソッド説明reactor.core.publisher.Mono<VoidSE>WebSocketSession.close(CloseStatus status) 指定されたステータスで WebSocket セッションを閉じます。booleanCloseStatus.equalsCode(CloseStatus other) 使用すべきではありません。5.3 以降、コードを直接比較するorg.springframework.web.reactive.socket.adapter 内の CloseStatus 使用
型 CloseStatus の引数を持つ型を返す org.springframework.web.reactive.socket.adapter のメソッド修飾子と型メソッド説明reactor.core.publisher.Mono<CloseStatus>AbstractListenerWebSocketSession.closeStatus()reactor.core.publisher.Mono<CloseStatus>ReactorNetty2WebSocketSession.closeStatus()reactor.core.publisher.Mono<CloseStatus>ReactorNettyWebSocketSession.closeStatus()型 CloseStatus のパラメーターを持つ org.springframework.web.reactive.socket.adapter のメソッド修飾子と型メソッド説明reactor.core.publisher.Mono<VoidSE>JettyWebSocketSession.close(CloseStatus status) reactor.core.publisher.Mono<VoidSE>ReactorNetty2WebSocketSession.close(CloseStatus status) reactor.core.publisher.Mono<VoidSE>ReactorNettyWebSocketSession.close(CloseStatus status) reactor.core.publisher.Mono<VoidSE>StandardWebSocketSession.close(CloseStatus status) reactor.core.publisher.Mono<VoidSE>UndertowWebSocketSession.close(CloseStatus status)