KycDocumentPageTranslator   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 10
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 2

Importance

Changes 0
Metric Value
wmc 1
lcom 0
cbo 2
dl 0
loc 10
rs 10
c 0
b 0
f 0

1 Method

Rating   Name   Duplication   Size   Complexity  
A convertDTOToMangoKycDocumentpage() 0 7 1
1
<?php
2
/**
3
 * Created by Carl Owens ([email protected])
4
 * Company: PartFire Ltd (www.partfire.co.uk)
5
 * Copyright © 2016 PartFire Ltd. All rights reserved.
6
 *
7
 * User:    Carl Owens
8
 * Date:    06/12/2016
9
 * Time:    21:32
10
 * File:    KycDocumentPageTranslator.php
11
 **/
12
13
namespace PartFire\MangoPayBundle\Models\DTOs\Translators;
14
15
16
use MangoPay\KycPage;
17
use PartFire\MangoPayBundle\Models\DTOs\KycDocumentPage;
18
19
class KycDocumentPageTranslator
20
{
21
    public function convertDTOToMangoKycDocumentpage(KycDocumentPage $kycDocumentPageDto)
22
    {
23
        $fileData = file_get_contents($kycDocumentPageDto->getFilePath());
24
        $mangoKycDocumentPage = new KycPage();
25
        $mangoKycDocumentPage->File = $fileData;
26
        return $mangoKycDocumentPage;
27
    }
28
}