CurlClientFactory   A
last analyzed

Complexity

Total Complexity 1

Size/Duplication

Total Lines 13
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 1
c 1
b 0
f 0
lcom 0
cbo 1
dl 0
loc 13
rs 10

1 Method

Rating   Name   Duplication   Size   Complexity  
A createClient() 0 4 1
1
<?php
2
namespace Metfan\RabbitSetup\Factory;
3
4
use Metfan\RabbitSetup\Http\CurlClient;
5
6
7
/**
8
 * Factory for http curl client class
9
 *
10
 * @author Ulrich
11
 * @package Metfan\Factory
12
 */
13
class CurlClientFactory
14
{
15
    /**
16
     * controle $options and return newly created CurlClient instance
17
     *
18
     * @param $options
19
     * @return CurlClient
20
     */
21
    public function createClient($options)
22
    {
23
        return new CurlClient($options['host'], $options['port'], $options['user'], $options['password']);
24
    }
25
}
26