Class UnexpectedElementException

    • Method Detail

      • getUnexpectedElement

        public Object getUnexpectedElement()
        Gets the unexpected element.
        Returns:
        the unexpected element
      • getPosition

        public int getPosition()
        Gets the position of the unexpected element.
        Returns:
        the position of the unexpected element
      • getExpectedElementTypes

        public Stream.ElementType<?>[] getExpectedElementTypes()
        Gets the expected element types.
        Returns:
        an array of expected element types
      • toString

        public String toString()
        Returns the string representation of this exception containing the information about the unexpected element and, if available, about the expected types.
        Overrides:
        toString in class Throwable
        Returns:
        the string representation of this exception