org.h2.util

## Class ParserUtil

- java.lang.Object
- - org.h2.util.ParserUtil

    public class ParserUtil
    extends java.lang.Object

### Field Summary

Fields
`static int` `FALSE` The token "false".
`static int` `IDENTIFIER` An identifier (table name, column name,...).
`static int` `KEYWORD` A keyword.
`static int` `NULL` The token "null".
`static int` `ROWNUM` The token "rownum".
`static int` `TRUE` The token "true".

### Method Summary

Methods
`static int` `getSaveTokenType(java.lang.String s, boolean functionsAsKeywords)` Get the token type.
`static boolean` `isKeyword(java.lang.String s)` Checks if this string is a SQL keyword.
`static boolean` `isSimpleIdentifier(java.lang.String s, boolean functionsAsKeywords)` Is this a simple identifier (in the JDBC specification sense).

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

### Field Detail

#### KEYWORD

    public static final int KEYWORD

A keyword.

See Also:
  Constant Field Values

#### IDENTIFIER

    public static final int IDENTIFIER

An identifier (table name, column name,...).

See Also:
  Constant Field Values

#### NULL

    public static final int NULL

The token "null".

See Also:
  Constant Field Values

#### TRUE

    public static final int TRUE

The token "true".

See Also:
  Constant Field Values

#### FALSE

    public static final int FALSE

The token "false".

See Also:
  Constant Field Values

#### ROWNUM

    public static final int ROWNUM

The token "rownum".

See Also:
  Constant Field Values

### Method Detail

#### isKeyword

    public static boolean isKeyword(java.lang.String s)

Checks if this string is a SQL keyword.

Parameters:
  `s` - the token to check
Returns:
  true if it is a keyword

#### isSimpleIdentifier

    public static boolean isSimpleIdentifier(java.lang.String s,
                             boolean functionsAsKeywords)

Is this a simple identifier (in the JDBC specification sense).

Parameters:
  `s` - identifier to check
  `functionsAsKeywords` - treat system functions as keywords
Returns:
  is specified identifier may be used without quotes
Throws:
  `java.lang.NullPointerException` - if s is `null`

#### getSaveTokenType

    public static int getSaveTokenType(java.lang.String s,
                       boolean functionsAsKeywords)

Get the token type.

Parameters:
  `s` - the token
  `functionsAsKeywords` - whether "current data / time" functions are keywords
Returns:
  the token type