Class DiagnosticUtils

java.lang.Object
org.eclipse.lemminx.commons.DiagnosticUtils

public class DiagnosticUtils extends Object
Utilities for Diagnostic.
Author:
Arun Venmany
  • Method Details

    • getDiagnosticMessage

      public static String getDiagnosticMessage(org.eclipse.lsp4j.Diagnostic diagnostic)
      Extracts the diagnostic message as a String from Eitherinvalid input: '<'String, MarkupContent>.

      In LSP4J 1.0.0, diagnostic messages can be either plain strings or rich MarkupContent. This method extracts the plain text representation from either format.

      Parameters:
      diagnostic - the diagnostic
      Returns:
      the diagnostic message as a String