Class ChunkerMixin.PeekStream

java.lang.Object
io.deephaven.lang.generated.ChunkerMixin.PeekStream
Enclosing interface:
ChunkerMixin

public static class ChunkerMixin.PeekStream extends Object
A stream specialized for "peek ahead" during semantic LOOKAHEAD. Normally, lookahead will assign tokens as it is looking ahead, but this can be problematic, as it can mis-identify and assign a token, causing the real match to be missed. We instead use direct access to tokens and underlying streams, so we can manually identify which paths to take; this can cause our peekaheads to be called multiple times at the same place (since we aren't assigning tokens for quick re-lookup), but we can ameliorate that performance with some light memoization on tokens (later).
  • Method Details

    • whitespace

      public ChunkerMixin.PeekStream whitespace()
    • ws

      public io.deephaven.lang.generated.ChunkerMixin.PeekStream.Checker ws()
    • ws

      public io.deephaven.lang.generated.ChunkerMixin.PeekStream.Checker ws(boolean required)
    • identifier

      public ChunkerMixin.PeekStream identifier(Set<Character> allowedEndings)
    • eofOr

      public ChunkerMixin.PeekStream eofOr(char... cs)
    • assign

      public ChunkerMixin.PeekStream assign()
    • eof

      public io.deephaven.lang.generated.ChunkerMixin.PeekStream.EofChecker eof(char... cs)
    • exact

      public ChunkerMixin.PeekStream exact(char... cs)
    • exact

      public ChunkerMixin.PeekStream exact(String cs)
    • is

      public io.deephaven.lang.generated.ChunkerMixin.PeekStream.Checker is(char... cs)
    • is

      public io.deephaven.lang.generated.ChunkerMixin.PeekStream.Checker is(String s)
    • matches

      public boolean matches(boolean peeking)