@@ -102,10 +102,6 @@ public SQLDatabaseConnection(SQLConnectionFactory connectionFactory) {
102102 * @return Collection of row objects.
103103 */
104104 public abstract <T > QueryRowsResult <T > query (Query query , Class <T > typeClass );
105-
106- /**
107- * @see SQLDatabaseConnection#query(Query, Class)
108- */
109105 public abstract QueryRowsResult <Row > query (Query query );
110106
111107 /**
@@ -122,14 +118,39 @@ public SQLDatabaseConnection(SQLConnectionFactory connectionFactory) {
122118 public abstract boolean isLogSqlErrors ();
123119 public abstract boolean isDebug ();
124120
125- public abstract SelectQuery select (String ... cols );
126- public abstract UpdateQuery update ();
127- public abstract UpdateQuery update (@ Nullable String table );
128- public abstract InsertQuery insert ();
129- public abstract InsertQuery insert (@ Nullable String table );
130- public abstract UpsertQuery upsert ();
131- public abstract UpsertQuery upsert (@ Nullable String table );
132- public abstract DeleteQuery delete ();
121+ // --***-- Query builders --***--
122+
123+ public SelectQuery select (String ... cols ) {
124+ return new SelectQuery (this , cols );
125+ }
126+
127+ public UpdateQuery update () {
128+ return update (null );
129+ }
130+
131+ public UpdateQuery update (@ Nullable String table ) {
132+ return new UpdateQuery (this , table );
133+ }
134+
135+ public InsertQuery insert () {
136+ return insert (null );
137+ }
138+
139+ public InsertQuery insert (@ Nullable String table ) {
140+ return new InsertQuery (this , table );
141+ }
142+
143+ public UpsertQuery upsert () {
144+ return upsert (null );
145+ }
146+
147+ public UpsertQuery upsert (@ Nullable String table ) {
148+ return new UpsertQuery (this , table );
149+ }
150+
151+ public DeleteQuery delete () {
152+ return new DeleteQuery (this );
153+ }
133154
134155 @ Override
135156 public boolean connect () {
0 commit comments