SODA
allows to create a query graph of any complexity by joining field object
constraints. SODA
usage is very generic and can be applied to any objects and conditions. The
following 5 steps can be used (all steps are optional and can be repeated
logically):
Query queryRootNode = db.query();
queryRootNode.constrain(Foo.class);
Query barNode = queryRootNode.descend("bar");
Constraint barConstraint = barNode.constrain(5);
barConstraint().greater();
The API is very powerful with a small number of method calls.
The "backward" order to add constraints first and to specify the evaluation mode as a second step allows plugging complex objects into a query.