PgUtil

Collection of utilities used by the protocol-level code.

Ported from org.postgresql.core.Utils

Members

Static functions

escapeIdentifier
StringBuilder escapeIdentifier(StringBuilder sbuf, string value)

Escape the given identifier <tt>value</tt> and append it to the string builder <tt>sbuf</tt>. If <tt>sbuf</tt> is <tt>null</tt>, a new StringBuilder will be returned. This method is different from appendEscapedLiteral in that it includes the quoting required for the identifier while {@link #escapeLiteral(StringBuilder, string, bool)} does not.

escapeLiteral
StringBuilder escapeLiteral(StringBuilder sbuf, string value, bool standardConformingStrings)

Escape the given literal <tt>value</tt> and append it to the string builder <tt>sbuf</tt>. If <tt>sbuf</tt> is <tt>null</tt>, a new StringBuilder will be returned. The argument <tt>standardConformingStrings</tt> defines whether the backend expects standard-conforming string literals or allows backslash escape sequences.

escapeWithQuotes
string escapeWithQuotes(string value)
Undocumented in source. Be warned that the author may not have intended to support it.

Meta