| Total Complexity | 3 |
| Total Lines | 47 |
| Duplicated Lines | 0 % |
| Coverage | 100% |
| Changes | 0 | ||
| 1 | <?php |
||
| 14 | class CreateEntity implements MutatorInterface |
||
| 15 | { |
||
| 16 | const CREATED_AT = 'created_at'; |
||
| 17 | |||
| 18 | /** |
||
| 19 | * @var array |
||
| 20 | */ |
||
| 21 | protected $data = array(); |
||
| 22 | |||
| 23 | /** |
||
| 24 | * @var string |
||
| 25 | */ |
||
| 26 | protected $dateFormat = 'Y-m-d H:i:s'; |
||
| 27 | |||
| 28 | /** |
||
| 29 | * @var string |
||
| 30 | */ |
||
| 31 | protected $table = ''; |
||
| 32 | |||
| 33 | /** |
||
| 34 | * @var boolean |
||
| 35 | */ |
||
| 36 | protected $timestamp = true; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * Initializes the mutator instance. |
||
| 40 | * |
||
| 41 | * @param array $data |
||
| 42 | */ |
||
| 43 | 6 | public function __construct(array $data) |
|
| 46 | 6 | } |
|
| 47 | |||
| 48 | /** |
||
| 49 | * Mutates the specified query instance. |
||
| 50 | * |
||
| 51 | * @param \Rougin\Windstorm\QueryInterface $query |
||
| 52 | */ |
||
| 53 | 6 | public function set(QueryInterface $query) |
|
| 63 |