partial void ExtractFailureContent(
            string?content,
            ref string?message,
            ref string?errorCode,
#pragma warning disable CA1801 // Remove unused parameter
            ref IDictionary <string, string>?additionalInfo)
#pragma warning restore CA1801 // Remove unused parameter
        {
            if (!string.IsNullOrEmpty(content))
            {
                try
                {
                    // Try to parse the failure content and use that as the
                    // default value for the message, error code, etc.
                    using JsonDocument doc = JsonDocument.Parse(content);
                    if (doc.RootElement.TryGetProperty("error", out JsonElement errorElement))
                    {
                        TextAnalyticsError error = TextAnalyticsServiceSerializer.ReadTextAnalyticsError(errorElement);
                        message   = error.Message;
                        errorCode = error.ErrorCode.ToString();
                    }
                }
                catch (JsonException)
                {
                    // Ignore any failures - unexpected content will be
                    // included verbatim in the detailed error message
                }
            }
        }
 internal TextAnalyticsResult(string id, TextAnalyticsError error)
 {
     Id    = id;
     Error = error;
 }
 public ErrorEntity(string id, TextAnalyticsError error)
 {
     Id    = id;
     Error = error;
 }