Codota Logo
Parser
Code IndexAdd Codota to your IDE (free)

How to use
Parser
in
org.postgresql.core

Best Java code snippets using org.postgresql.core.Parser (Showing top 20 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
BufferedReader b =
  • Codota IconInputStream in;new BufferedReader(new InputStreamReader(in))
  • Codota IconReader in;new BufferedReader(in)
  • Codota IconFile file;new BufferedReader(new FileReader(file))
  • Smart code suggestions by Codota
}
origin: org.postgresql/postgresql

 && offset >= 2
 && (query[offset - 1] == 'e' || query[offset - 1] == 'E')
 && charTerminatesIdentifier(query[offset - 2])) {
standardConformingStrings = false;
origin: org.postgresql/postgresql

 && (offset == 0 || !isIdentifierContChar(query[offset - 1]))) {
int endIdx = -1;
if (query[offset + 1] == '$') {
 endIdx = offset + 1;
} else if (isDollarQuoteStartChar(query[offset + 1])) {
 for (int d = offset + 2; d < query.length; ++d) {
  if (query[d] == '$') {
   endIdx = d;
   break;
  } else if (!isDollarQuoteContChar(query[d])) {
   break;
    && subArraysEqual(query, tagIdx, offset, tagLen)) {
   offset += tagLen - 1;
   break;
origin: org.postgresql/postgresql

/**
 * @param c character
 * @return true if the character terminates an identifier
 */
public static boolean charTerminatesIdentifier(char c) {
 return c == '"' || isSpace(c) || isOperatorChar(c);
}
origin: org.postgresql/postgresql

if (wordLength == 6 && parseUpdateKeyword(aChars, keywordStart)) {
 command = SqlCommandType.UPDATE;
} else if (wordLength == 6 && parseDeleteKeyword(aChars, keywordStart)) {
 command = SqlCommandType.DELETE;
} else if (wordLength == 6 && parseInsertKeyword(aChars, keywordStart)) {
 command = SqlCommandType.INSERT;
} else if (wordLength == 6 && parseSelectKeyword(aChars, keywordStart)) {
 command = SqlCommandType.SELECT;
} else {
 char nextChar = aChars[nextInd];
 if (nextChar == '-') {
  nextInd = Parser.parseLineComment(aChars, nextInd);
 } else if (nextChar == '/') {
  nextInd = Parser.parseBlockComment(aChars, nextInd);
 } else if (Character.isWhitespace(nextChar)) {
  || (!parseAsKeyword(aChars, nextInd)
  || isIdentifierContChar(aChars[nextInd + 2]))) {
 return command;
origin: postgresql/postgresql

i = Parser.parseSingleQuotes(aChars, i, stdStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
origin: org.postgresql/postgresql

i = Parser.parseSingleQuotes(aChars, i, standardConformingStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
  if (addReturning(nativeSql, currentCommandType, returningColumnNames, isReturningPresent)) {
   isReturningPresent = true;
     toIntArray(bindPositions), false,
     SqlCommand.createStatementTypeInfo(
       currentCommandType, isBatchedReWriteConfigured, valuesBraceOpenPosition,
 isKeyWordChar = isIdentifierContChar(aChar);
 break;
isKeyWordChar = isIdentifierStartChar(aChar);
if (isKeyWordChar) {
 keywordStart = i;
origin: org.postgresql/postgresql

if (c == '$') {
 int i0 = i;
 i = parseDollarQuotes(p_sql, i);
 checkParsePosition(i, len, i0, p_sql,
   "Unterminated dollar quote started at position {0} in SQL {1}. Expected terminating $$");
 newsql.append(p_sql, i0, i - i0 + 1);
 i = parseSingleQuotes(p_sql, i, stdStrings);
 checkParsePosition(i, len, i0, p_sql,
   "Unterminated string literal started at position {0} in SQL {1}. Expected ' char");
 newsql.append(p_sql, i0, i - i0 + 1);
 i = parseDoubleQuotes(p_sql, i);
 checkParsePosition(i, len, i0, p_sql,
   "Unterminated identifier started at position {0} in SQL {1}. Expected \" char");
 newsql.append(p_sql, i0, i - i0 + 1);
} else if (c == '/') {
 int i0 = i;
 i = parseBlockComment(p_sql, i);
 checkParsePosition(i, len, i0, p_sql,
   "Unterminated block comment started at position {0} in SQL {1}. Expected */ sequence");
 newsql.append(p_sql, i0, i - i0 + 1);
} else if (c == '-') {
 int i0 = i;
 i = parseLineComment(p_sql, i);
 newsql.append(p_sql, i0, i - i0 + 1);
 break;
origin: org.postgresql/postgresql

/**
 * Checks if a character is valid as the second or later character of a dollar quoting tag.
 *
 * @param c the character to check
 * @return true if valid as second or later character of a dollar quoting tag; false if not
 */
public static boolean isDollarQuoteContChar(char c) {
 return c != '$' && isIdentifierContChar(c);
}
origin: postgresql/postgresql

i = Parser.parseSingleQuotes(aChars, i, standardConformingStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
origin: org.ancoron.postgresql/org.postgresql

i = Parser.parseSingleQuotes(aChars, i, stdStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
origin: postgresql/postgresql

  && (offset == 0 || !isIdentifierContChar(query[offset-1])))
else if (isDollarQuoteStartChar(query[offset + 1]))
      break;
    else if (!isDollarQuoteContChar(query[d]))
      break;
      subArraysEqual(query, tagIdx, offset, tagLen))
origin: postgresql/postgresql

/**
 * @return true if the character terminates an identifier
 */
public static boolean charTerminatesIdentifier(char c) {
  return c == '"' || isSpace(c) || isOperatorChar(c);
}
origin: postgresql/postgresql

&& offset >= 2
&& (query[offset-1] == 'e' || query[offset-1] == 'E')
&& charTerminatesIdentifier(query[offset-2]))
origin: org.ancoron.postgresql/org.postgresql.osgi

i = Parser.parseSingleQuotes(aChars, i, stdStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
origin: org.ancoron.postgresql/org.postgresql.osgi

  && (offset == 0 || !isIdentifierContChar(query[offset-1])))
else if (isDollarQuoteStartChar(query[offset + 1]))
      break;
    else if (!isDollarQuoteContChar(query[d]))
      break;
      subArraysEqual(query, tagIdx, offset, tagLen))
origin: org.ancoron.postgresql/org.postgresql

/**
 * @return true if the character terminates an identifier
 */
public static boolean charTerminatesIdentifier(char c) {
  return c == '"' || isSpace(c) || isOperatorChar(c);
}
origin: org.ancoron.postgresql/org.postgresql.osgi

&& offset >= 2
&& (query[offset-1] == 'e' || query[offset-1] == 'E')
&& charTerminatesIdentifier(query[offset-2]))
origin: org.ancoron.postgresql/org.postgresql.osgi

i = Parser.parseSingleQuotes(aChars, i, standardConformingStrings);
break;
i = Parser.parseDoubleQuotes(aChars, i);
break;
i = Parser.parseLineComment(aChars, i);
break;
i = Parser.parseBlockComment(aChars, i);
break;
i = Parser.parseDollarQuotes(aChars, i);
break;
origin: org.ancoron.postgresql/org.postgresql

  && (offset == 0 || !isIdentifierContChar(query[offset-1])))
else if (isDollarQuoteStartChar(query[offset + 1]))
      break;
    else if (!isDollarQuoteContChar(query[d]))
      break;
      subArraysEqual(query, tagIdx, offset, tagLen))
origin: org.ancoron.postgresql/org.postgresql.osgi

/**
 * @return true if the character terminates an identifier
 */
public static boolean charTerminatesIdentifier(char c) {
  return c == '"' || isSpace(c) || isOperatorChar(c);
}
org.postgresql.coreParser

Javadoc

Basic query parser infrastructure.

Most used methods

  • charTerminatesIdentifier
  • isDollarQuoteContChar
    Checks if a character is valid as the second or later character of a dollar quoting tag.
  • isDollarQuoteStartChar
    Checks if a character is valid as the start of a dollar quoting tag.
  • isIdentifierContChar
    Checks if a character is valid as the second or later character of an identifier.
  • isOperatorChar
  • isSpace
  • parseBlockComment
    Test if the / character at offset starts a block comment, and return the position of the last / char
  • parseDollarQuotes
    Test if the dollar character ($) at the given offset starts a dollar-quoted string and return the of
  • parseDoubleQuotes
    Find the end of the double-quoted string starting at the given offset. Note: for "double "" quote i
  • parseLineComment
    Test if the - character at offset starts a-- style line comment, and return the position of the firs
  • parseSingleQuotes
    Find the end of the single-quoted string starting at the given offset. Note: for 'single '' quote i
  • subArraysEqual
    Compares two sub-arrays of the given character array for equalness. If the length is zero, the resul
  • parseSingleQuotes,
  • subArraysEqual,
  • addReturning,
  • checkParsePosition,
  • digitAt,
  • escapeFunction,
  • escapeFunctionArguments,
  • findOpenBrace,
  • isDigitAt,
  • isIdentifierStartChar

Popular in Java

  • Updating database using SQL prepared statement
  • putExtra (Intent)
  • getOriginalFilename (MultipartFile)
    Return the original filename in the client's filesystem.This may contain path information depending
  • getContentResolver (Context)
  • GridLayout (java.awt)
    The GridLayout class is a layout manager that lays out a container's components in a rectangular gri
  • LinkedList (java.util)
    Doubly-linked list implementation of the List and Dequeinterfaces. Implements all optional list oper
  • BlockingQueue (java.util.concurrent)
    A java.util.Queue that additionally supports operations that wait for the queue to become non-empty
  • JarFile (java.util.jar)
    JarFile is used to read jar entries and their associated data from jar files.
  • SSLHandshakeException (javax.net.ssl)
    The exception that is thrown when a handshake could not be completed successfully.
  • JFileChooser (javax.swing)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now