1 | <?php |
||
14 | class Anonymizer |
||
15 | { |
||
16 | const __CLASS = __CLASS__; |
||
17 | /** |
||
18 | * @var Provider |
||
19 | */ |
||
20 | private $provider; |
||
21 | |||
22 | /** |
||
23 | * @param Provider $provider |
||
24 | * @param string $locale |
||
25 | */ |
||
26 | function __construct(Provider $provider = null, $locale = null) |
||
34 | |||
35 | /** |
||
36 | * @param AnonymizableEntity[] $inputData |
||
37 | */ |
||
38 | public function anonymize(array $inputData) |
||
47 | |||
48 | /** |
||
49 | * Returns identifier for a field, based on entity and current value. This is used to map real data to fake |
||
50 | * data in the same way for each unique entity identifier (i.e. customer id) |
||
51 | * |
||
52 | * @param AnonymizableEntity $entity |
||
53 | * @param AnonymizableValue $value |
||
54 | * @return string |
||
55 | */ |
||
56 | private function _getFieldIdentifier(AnonymizableEntity $entity, AnonymizableValue $value) |
||
60 | |||
61 | public function resetUniqueGenerator() |
||
65 | } |
Adding explicit visibility (
private
,protected
, orpublic
) is generally recommend to communicate to other developers how, and from where this method is intended to be used.