Class StrParser


  • public class StrParser
    extends Object
    Simple class to help with parsing a string. Note: This API is experimental and may change in non backward-compatible ways in the future
    • Field Detail

      • pos

        public int pos
      • end

        public int end
    • Constructor Detail

      • StrParser

        public StrParser​(String val)
      • StrParser

        public StrParser​(String val,
                         int start,
                         int end)
    • Method Detail

      • eatws

        public void eatws()
      • ch

        public char ch()
      • skip

        public void skip​(int nChars)
      • opt

        public boolean opt​(String s)
      • opt

        public boolean opt​(char ch)
      • getFloat

        public float getFloat()
      • getNumber

        public Number getNumber()
      • getDouble

        public double getDouble()
      • getInt

        public int getInt()
      • getSimpleString

        public String getSimpleString()
        Skips leading whitespace and returns whatever sequence of non whitespace it can find (or hte empty string)
      • getSortDirection

        public Boolean getSortDirection()
                                 throws SyntaxError
        Sort direction or null if current position does not indicate a sort direction. (True is desc, False is asc). Position is advanced to after the comma (or end) when result is non null
        Throws:
        SyntaxError
      • peek

        public char peek()
      • peekChar

        public char peekChar()