Filter expression

This section describes the syntax of the setFilter() argument.

Basically, the query filter expression is a Java boolean expression, where some of the Java expressions are not permitted. Specifically, pre- and post-increment and decrement (++ and − −), shift (>> and <<), and assignment expressions (+=, −=, etc.) are not permitted.

The description follows the structure of the grammar for Java expression in Chapter 19.12 of the Java Language Specification (Joy et al., 2000). The description is bottom-up, i.e. the last rule expression is the root of the filter expression syntax.

Please note, the grammar allows arbitrary method calls (MethodInvocation), where JDO only permits calls to the methods contains() , isEmpty() , and a number ...

Get Java™ Data Objects now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.