Class GQLToken

  • All Implemented Interfaces:
    java.lang.CharSequence, java.lang.Comparable<net.morimekta.util.CharSlice>, net.morimekta.util.Stringable

    public class GQLToken
    extends net.morimekta.util.lexer.Token<GQLTokenType>
    • Constructor Summary

      Constructors 
      Constructor Description
      GQLToken​(char[] fb, int off, int len, GQLTokenType type, int lineNo, int linePos)
      Create a slice instance.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean isDirectve()  
      boolean isIdentifier()  
      boolean isString()  
      boolean isVariable()  
      • Methods inherited from class net.morimekta.util.lexer.Token

        decodeString, equals, hashCode, isSymbol, line, lineNo, linePos, type
      • Methods inherited from class net.morimekta.util.CharSlice

        asString, charAt, compareTo, contains, contains, containsAny, length, offset, parseDouble, parseInteger, strEquals, strEquals, subSequence, substring, toString
      • Methods inherited from class java.lang.Object

        clone, finalize, getClass, notify, notifyAll, wait, wait, wait
      • Methods inherited from interface java.lang.CharSequence

        chars, codePoints
    • Constructor Detail

      • GQLToken

        public GQLToken​(char[] fb,
                        int off,
                        int len,
                        @Nonnull
                        GQLTokenType type,
                        int lineNo,
                        int linePos)
        Create a slice instance. The slice is only meant to be internal state immutable, and not representing an immutable byte content.
        Parameters:
        fb - The buffer to wrap.
        off - The start offset to wrap.
        len - The length to represent.
        type - The token type represented.
        lineNo - The current line number.
        linePos - The current line position.
    • Method Detail

      • isString

        public boolean isString()
      • isIdentifier

        public boolean isIdentifier()
      • isVariable

        public boolean isVariable()
      • isDirectve

        public boolean isDirectve()