Class ResponseAttributesHelper

java.lang.Object
com.mulesoft.connectors.a2a.internal.client.helper.ResponseAttributesHelper

public class ResponseAttributesHelper extends Object
Utility class for creating ResponseAttributes objects from HTTP responses.
  • Method Details

    • createFromHttpResponse

      public static ResponseAttributes createFromHttpResponse(org.mule.runtime.http.api.domain.message.response.HttpResponse response)
      Creates ResponseAttributes from an HTTP response.
      Parameters:
      response - the HTTP response
      Returns:
      ResponseAttributes object with status code, headers, and reason phrase
    • createStreamingFromResponseAttributes

      public static StreamingResponseAttributes createStreamingFromResponseAttributes(ResponseAttributes originalAttributes, Boolean finalEventFound)
      Creates StreamingResponseAttributes from existing ResponseAttributes with final event information.
      Parameters:
      originalAttributes - the original response attributes
      finalEventFound - whether a final event was found during the SSE session
      Returns:
      StreamingResponseAttributes object with enhanced streaming information