Annotation Interface SqlEvenQuotes


Denotes a String that contains either zero or an even number of unescaped single quotes — i.e., there must be either zero or an even number of characters in a SqlEvenQuotes String that are not preceded immediately by another character. (Thus, all SqlEvenQuotes Strings ultimately contain an even number of ' characters.) A SqlEvenQuotes String is syntactical to be passed to query execution methods and is guaranteed not to affect whether subsequent concatenations are interpreted as SQL command code or as SQL query values.

Common use cases include: SQL query fragments, such as “SELECT * FROM”; properly sanitized user input; and complete SQL queries, such as “SELECT * FROM table WHERE field = 'value'”.

See the Checker Framework Manual:
SQL Quotes Checker