Skip to content

Commit abdab9e

Browse files
Add JavaDocs for QueryGroup
1 parent 0201c3d commit abdab9e

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

src/main/java/org/javawebstack/orm/query/QueryGroup.java

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,15 @@
1010
import java.util.List;
1111
import java.util.function.Function;
1212

13+
/**
14+
* Queries grouped via the QueryGroup class will be put inside parenthesis.
15+
* This makes expressions as the following possible (MySQL example):
16+
* ... `column_a` = 'A' OR (`column_b` = 'B' AND `column_c´ = 'C') ...
17+
*
18+
* In the above example `column_b` = 'B' AND `column_c´ = 'C' would be in a QueryGroup.
19+
*
20+
* @param <T> The model under which the QueryGroups functions. Currently purely semantic without functionality.
21+
*/
1322
public class QueryGroup<T extends Model> implements QueryElement {
1423

1524
private final List<QueryElement> queryElements = new ArrayList<>();

0 commit comments

Comments
 (0)