@SuppressWarnings({ "unchecked", "rawtypes" }) public BooleanExpression instanceOfAny(Class... types) { BooleanExpression[] exprs = new BooleanExpression[types.length]; for (int i = 0; i < types.length; i++) { exprs[i] = this.instanceOf(types[i]); } return BooleanExpression.anyOf(exprs); }