forked from mathielen/import-engine
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
2 changed files
with
21 additions
and
13 deletions.
There are no files selected for viewing
21 changes: 21 additions & 0 deletions
21
src/Mathielen/DataImport/ItemConverter/FieldCaseConverter.php
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<?php | ||
|
||
namespace Mathielen\DataImport\ItemConverter; | ||
|
||
use Ddeboer\DataImport\ItemConverter\ItemConverterInterface; | ||
|
||
class FieldCaseConverter implements ItemConverterInterface | ||
{ | ||
|
||
private $transformToCase; | ||
|
||
public function __construct($transformToCase = CASE_LOWER) | ||
{ | ||
$this->transformToCase = $transformToCase; | ||
} | ||
|
||
public function convert($input) | ||
{ | ||
return array_change_key_case($input, $this->transformToCase); | ||
} | ||
} |
13 changes: 0 additions & 13 deletions
13
src/Mathielen/DataImport/ItemConverter/FieldLowercaseConverter.php
This file was deleted.
Oops, something went wrong.