Class TyrusUpgradeResponse

java.lang.Object
org.glassfish.tyrus.spi.UpgradeResponse
org.glassfish.tyrus.core.TyrusUpgradeResponse
All Implemented Interfaces:
HandshakeResponse

public class TyrusUpgradeResponse extends UpgradeResponse
HTTP response representation.
Author:
Pavel Bucek
  • Constructor Details

    • TyrusUpgradeResponse

      public TyrusUpgradeResponse()
  • Method Details

    • getStatus

      public int getStatus()
      Get HTTP status.
      Specified by:
      getStatus in class UpgradeResponse
      Returns:
      HTTP status.
    • getReasonPhrase

      public String getReasonPhrase()
      Get HTTP reason phrase.

      Warning: The Reason Phrase is removed from HTTP/2 and from Servlet 6.

      Specified by:
      getReasonPhrase in class UpgradeResponse
      Returns:
      reason phrase.
    • getHeaders

      public Map<String,List<String>> getHeaders()
      Get HTTP headers.
      Returns:
      HTTP headers.
    • setStatus

      public void setStatus(int statusCode)
      Set HTTP status.
      Specified by:
      setStatus in class UpgradeResponse
      Parameters:
      statusCode - status code to be set.
    • setReasonPhrase

      public void setReasonPhrase(String reasonPhrase)
      Set HTTP reason phrase.
      Specified by:
      setReasonPhrase in class UpgradeResponse
      Parameters:
      reasonPhrase - reason phrase to be set.