Class ResponseHighlighterInterceptor

java.lang.Object
ca.uhn.fhir.rest.server.interceptor.ResponseHighlighterInterceptor

This interceptor detects when a request is coming from a browser, and automatically returns a response with syntax highlighted (coloured) HTML for the response instead of just returning raw XML/JSON.
Since:
1.0
  • Field Details

  • Constructor Details

  • Method Details

    • handleException

      public boolean handleException(RequestDetails theRequestDetails, ca.uhn.fhir.rest.server.exceptions.BaseServerResponseException theException, javax.servlet.http.HttpServletRequest theServletRequest, javax.servlet.http.HttpServletResponse theServletResponse)
    • isShowRequestHeaders

      public boolean isShowRequestHeaders()
      If set to true (default is false) response will include the request headers
    • setShowRequestHeaders

      public ResponseHighlighterInterceptor setShowRequestHeaders(boolean theShowRequestHeaders)
      If set to true (default is false) response will include the request headers
      Returns:
      Returns a reference to this for easy method chaining
    • isShowResponseHeaders

      public boolean isShowResponseHeaders()
      If set to true (default is true) response will include the response headers
    • setShowResponseHeaders

      public ResponseHighlighterInterceptor setShowResponseHeaders(boolean theShowResponseHeaders)
      If set to true (default is true) response will include the response headers
      Returns:
      Returns a reference to this for easy method chaining
    • outgoingGraphqlResponse

      public boolean outgoingGraphqlResponse(RequestDetails theRequestDetails, String theRequest, String theResponse, javax.servlet.http.HttpServletRequest theServletRequest, javax.servlet.http.HttpServletResponse theServletResponse) throws ca.uhn.fhir.rest.server.exceptions.AuthenticationException
      Throws:
      ca.uhn.fhir.rest.server.exceptions.AuthenticationException
    • outgoingResponse

      public boolean outgoingResponse(RequestDetails theRequestDetails, ResponseDetails theResponseObject, javax.servlet.http.HttpServletRequest theServletRequest, javax.servlet.http.HttpServletResponse theServletResponse) throws ca.uhn.fhir.rest.server.exceptions.AuthenticationException
      Throws:
      ca.uhn.fhir.rest.server.exceptions.AuthenticationException
    • capabilityStatementGenerated

      public void capabilityStatementGenerated(RequestDetails theRequestDetails, org.hl7.fhir.instance.model.api.IBaseConformance theCapabilityStatement)