Class FormatterDiagnostic


  • public class FormatterDiagnostic
    extends java.lang.Object
    An error that prevented formatting from succeeding.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private int column  
      private int lineNumber  
      private java.lang.String message  
    • Constructor Summary

      Constructors 
      Modifier Constructor Description
      private FormatterDiagnostic​(int lineNumber, int column, java.lang.String message)  
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      int column()
      Returns the 0-indexed column number on which the error occurred, or -1 if the error does not have a column.
      static FormatterDiagnostic create​(int lineNumber, int column, java.lang.String message)  
      static FormatterDiagnostic create​(java.lang.String message)  
      int line()
      Returns the line number on which the error occurred, or -1 if the error does not have a line number.
      java.lang.String message()
      Returns a description of the problem that prevented formatting from succeeding.
      java.lang.String toString()  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
    • Field Detail

      • lineNumber

        private final int lineNumber
      • message

        private final java.lang.String message
      • column

        private final int column
    • Constructor Detail

      • FormatterDiagnostic

        private FormatterDiagnostic​(int lineNumber,
                                    int column,
                                    java.lang.String message)
    • Method Detail

      • create

        public static FormatterDiagnostic create​(int lineNumber,
                                                 int column,
                                                 java.lang.String message)
      • line

        public int line()
        Returns the line number on which the error occurred, or -1 if the error does not have a line number.
      • column

        public int column()
        Returns the 0-indexed column number on which the error occurred, or -1 if the error does not have a column.
      • message

        public java.lang.String message()
        Returns a description of the problem that prevented formatting from succeeding.
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object