javax.net.ssl

Class SSLEngineResult


  • public class SSLEngineResult
    extends Object
    An encapsulation of the result state produced by SSLEngine I/O calls.

    A SSLEngine provides a means for establishing secure communication sessions between two peers. SSLEngine operations typically consume bytes from an input buffer and produce bytes in an output buffer. This class provides operational result values describing the state of the SSLEngine, including indications of what operations are needed to finish an ongoing handshake. Lastly, it reports the number of bytes consumed and produced as a result of this operation.

    Since:
    1.5
    See Also:
    SSLEngine, SSLEngine.wrap(ByteBuffer, ByteBuffer), SSLEngine.unwrap(ByteBuffer, ByteBuffer)
    • Constructor Detail

      • SSLEngineResult

        public SSLEngineResult(SSLEngineResult.Status status,
                       SSLEngineResult.HandshakeStatus handshakeStatus,
                       int bytesConsumed,
                       int bytesProduced)
        Initializes a new instance of this class.
        Parameters:
        status - the return value of the operation.
        handshakeStatus - the current handshaking status.
        bytesConsumed - the number of bytes consumed from the source ByteBuffer
        bytesProduced - the number of bytes placed into the destination ByteBuffer
        Throws:
        IllegalArgumentException - if the status or handshakeStatus arguments are null, or if <bytesConsumed or bytesProduced is negative.
    • Method Detail

      • getStatus

        public final SSLEngineResult.Status getStatus()
        Gets the return value of this SSLEngine operation.
        Returns:
        the return value
      • getHandshakeStatus

        public final SSLEngineResult.HandshakeStatus getHandshakeStatus()
        Gets the handshake status of this SSLEngine operation.
        Returns:
        the handshake status
      • bytesConsumed

        public final int bytesConsumed()
        Returns the number of bytes consumed from the input buffer.
        Returns:
        the number of bytes consumed.
      • bytesProduced

        public final int bytesProduced()
        Returns the number of bytes written to the output buffer.
        Returns:
        the number of bytes produced
      • toString

        public String toString()
        Returns a String representation of this object.
        Overrides:
        toString in class Object
        Returns:
        a string representation of the object.

Traduction non disponible

Les API Java ne sont pas encore traduites en français sur l'infobrol. Seule la version anglaise est disponible pour l'instant.

Document créé le 30/08/2006, dernière modification le 04/03/2020
Source du document imprimé : https://www.gaudry.be/java-api-rf-javax/net/ssl/SSLEngineResult.html

L'infobrol est un site personnel dont le contenu n'engage que moi. Le texte est mis à disposition sous licence CreativeCommons(BY-NC-SA). Plus d'info sur les conditions d'utilisation et sur l'auteur.

Références

  1. Consulter le document html Langue du document :fr Manuel PHP : https://docs.oracle.com, SSLEngineResult

Ces références et liens indiquent des documents consultés lors de la rédaction de cette page, ou qui peuvent apporter un complément d'information, mais les auteurs de ces sources ne peuvent être tenus responsables du contenu de cette page.
L'auteur de ce site est seul responsable de la manière dont sont présentés ici les différents concepts, et des libertés qui sont prises avec les ouvrages de référence. N'oubliez pas que vous devez croiser les informations de sources multiples afin de diminuer les risques d'erreurs.

Table des matières Haut