Code Duplication    Length = 7-8 lines in 4 locations

source/Spiral/Database/Entities/Driver.php 4 locations

@@ 222-228 (lines=7) @@
219
     *
220
     * @return InsertQuery
221
     */
222
    public function insertBuilder(string $prefix, array $parameters = []): InsertQuery
223
    {
224
        return $this->factory->make(
225
            InsertQuery::class,
226
            ['driver' => $this, 'compiler' => $this->queryCompiler($prefix)] + $parameters
227
        );
228
    }
229
230
    /**
231
     * Get SelectQuery builder with driver specific query compiler.
@@ 239-245 (lines=7) @@
236
     *
237
     * @return SelectQuery
238
     */
239
    public function selectBuilder(string $prefix, array $parameters = []): SelectQuery
240
    {
241
        return $this->factory->make(
242
            SelectQuery::class,
243
            ['driver' => $this, 'compiler' => $this->queryCompiler($prefix)] + $parameters
244
        );
245
    }
246
247
    /**
248
     * Get DeleteQuery builder with driver specific query compiler.
@@ 256-263 (lines=8) @@
253
     *
254
     * @return DeleteQuery
255
     */
256
    public function deleteBuilder(string $prefix, array $parameters = []): DeleteQuery
257
    {
258
259
        return $this->factory->make(
260
            DeleteQuery::class,
261
            ['driver' => $this, 'compiler' => $this->queryCompiler($prefix)] + $parameters
262
        );
263
    }
264
265
    /**
266
     * Get UpdateQuery builder with driver specific query compiler.
@@ 274-280 (lines=7) @@
271
     *
272
     * @return UpdateQuery
273
     */
274
    public function updateBuilder(string $prefix, array $parameters = []): UpdateQuery
275
    {
276
        return $this->factory->make(
277
            UpdateQuery::class,
278
            ['driver' => $this, 'compiler' => $this->queryCompiler($prefix)] + $parameters
279
        );
280
    }
281
}
282