Class XmlResponseParserUtils


  • @SdkInternalApi
    public final class XmlResponseParserUtils
    extends Object
    Static methods to assist with parsing the response of AWS XML requests.
    • Method Detail

      • parse

        public static XmlElement parse​(SdkPojo sdkPojo,
                                       SdkHttpFullResponse response)
        Parse an XML response if one is expected and available. If we are not expecting a payload, but the HTTP response code shows an error then we will parse it anyway, as it should contain a serialized error.
        Parameters:
        sdkPojo - the SDK builder object associated with the final response
        response - the HTTP response
        Returns:
        A parsed XML document or an empty XML document if no payload/contents were found in the response.
      • getBlobTypePayloadMemberToUnmarshal

        public static Optional<SdkField<?>> getBlobTypePayloadMemberToUnmarshal​(SdkPojo sdkPojo)
        Gets the Member which is a Payload and which is of Blob Type.
        Parameters:
        sdkPojo -
        Returns:
        Optional of SdkField member if member is Blob type payload else returns Empty.