public class SSLEngineResult extends Object
SSLEngine入出力呼出しによって生成された結果状態のカプセル化。
  SSLEngineは、2つのピア間でセキュアな通信セッションを確立するための手段を提供します。 SSLEngineオペレーションは通常、入力バッファのバイトを使用し、出力バッファへバイトを書き出します。 このクラスは、オペレーションの結果を示す値を提供します。この値は、現行のハンドシェークを完了するために必要なオペレーションの指定を含めて、SSLEngineの状態を説明します。 このクラスは、最後に、このオペレーションの結果として、使用されたバイト数と書き出されたバイト数を報告します。 
SSLEngine, SSLEngine.wrap(ByteBuffer, ByteBuffer), SSLEngine.unwrap(ByteBuffer, ByteBuffer)| 修飾子と型 | クラス | 説明 | 
|---|---|---|
| static class  | SSLEngineResult.HandshakeStatus | この SSLEngineの現在のハンドシェーク状態を説明するSSLEngineResultの列挙型。 | 
| static class  | SSLEngineResult.Status | SSLEngineオペレーションの全体的な結果を説明するSSLEngineResultの列挙型。 | 
| コンストラクタ | 説明 | 
|---|---|
| SSLEngineResult(SSLEngineResult.Status status, SSLEngineResult.HandshakeStatus handshakeStatus, int bytesConsumed, int bytesProduced) | このクラスの新しいインスタンスを初期化します。 | 
| 修飾子と型 | メソッド | 説明 | 
|---|---|---|
| int | bytesConsumed() | 入力バッファから使用されたバイト数を返します。 | 
| int | bytesProduced() | 出力バッファへ書き込まれたバイト数を返します。 | 
| SSLEngineResult.HandshakeStatus | getHandshakeStatus() | この SSLEngineオペレーションのハンドシェーク状態を取得します。 | 
| SSLEngineResult.Status | getStatus() | この SSLEngineオペレーションの戻り値を取得します。 | 
| String | toString() | このオブジェクトの文字列表現を返します。 | 
public SSLEngineResult(SSLEngineResult.Status status, SSLEngineResult.HandshakeStatus handshakeStatus, int bytesConsumed, int bytesProduced)
status - このオペレーションの戻り値。handshakeStatus - 現在のハンドシェーク状態。bytesConsumed - ソースのByteBufferから使用されたバイト数bytesProduced - 宛先ByteBufferに書き出されたバイト数IllegalArgumentException - statusかhandshakeStatusのいずれかの引数がnullの場合、またはbytesConsumedかbytesProducedが負の値の場合。public final SSLEngineResult.Status getStatus()
SSLEngineオペレーションの戻り値を取得します。public final SSLEngineResult.HandshakeStatus getHandshakeStatus()
SSLEngineオペレーションのハンドシェーク状態を取得します。public final int bytesConsumed()
public final int bytesProduced()
 バグまたは機能を送信 
詳細なAPIリファレンスおよび開発者ドキュメントについては、Java SEのドキュメントを参照してください。 そのドキュメントには、概念的な概要、用語の定義、回避方法、有効なコード例などの、開発者を対象にしたより詳細な説明が含まれています。 
 Copyright © 1993, 2025, Oracle and/or its affiliates.  All rights reserved.  Use is subject to license terms.  Documentation Redistribution Policyも参照してください。