Completed
Push — 2.0 ( 1160ec...acba87 )
by Vermeulen
05:15
created

Delete::obtainGenerateOrder()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 10

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
dl 0
loc 10
c 0
b 0
f 0
rs 9.9332
cc 1
nc 1
nop 0
1
<?php
2
3
namespace BfwSql\Queries;
4
5
/**
6
 * Class to write DELETE queries
7
 * 
8
 * @package bfw-sql
9
 * @author Vermeulen Maxime <[email protected]>
10
 * @version 2.0
11
 */
12
class Delete extends AbstractQuery
13
{
14
    /**
15
     * {@inheritdoc}
16
     */
17
    protected function defineQueriesParts()
18
    {
19
        parent::defineQueriesParts();
20
        
21
        $this->queriesParts['from'] = $this->queriesParts['table'];
22
    }
23
    
24
    /**
25
     * {@inheritdoc}
26
     */
27
    protected function obtainGenerateOrder(): array
28
    {
29
        return [
30
            'from' => [
31
                'prefix'     => 'DELETE FROM',
32
                'canBeEmpty' => false
33
            ],
34
            'where' => []
35
        ];
36
    }
37
}
38