Once upon a time did it with the help of JavaCC:
filterCondition.jj to search the tables Vaadin, but can be applied to ordinary collections.
The user filter table in the following way:
1.
Value1,Value2,Value3 - filter according to one of three values
2.
Field1 = Value1 or (Field2 is NOT EMPTY Field3 > 5) - integrated filter