Interface ITokenTypeRemapper

Functional Interface:
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface ITokenTypeRemapper
  • Method Summary

    Modifier and Type
    Method
    Description
    filter(IElementType source, int start, int end, CharSequence text)
    An external hook to see and alter token types reported by lexer.
  • Method Details

    • filter

      IElementType filter(IElementType source, int start, int end, CharSequence text)
      An external hook to see and alter token types reported by lexer. A lexer might take a delegate implementing this interface.
      Parameters:
      source - type of an element as lexer understood it.
      start - start index of lexeme in text (as lexer.getTokenStart() would return).
      end - end index of lexeme in text (as lexer.getTokenEnd() would return).
      text - text being parsed.
      Returns:
      altered (or not) element type.