Connections   A
last analyzed

Complexity

Total Complexity 3

Size/Duplication

Total Lines 31
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 3

Test Coverage

Coverage 0%

Importance

Changes 0
Metric Value
wmc 3
lcom 0
cbo 3
dl 0
loc 31
ccs 0
cts 6
cp 0
rs 10
c 0
b 0
f 0

3 Methods

Rating   Name   Duplication   Size   Complexity  
A tableName() 0 4 1
A connectionInstance() 0 4 1
A getDefaultConnection() 0 4 1
1
<?php
2
3
/**
4
 * @copyright  Copyright (c) Flipbox Digital Limited
5
 * @license    https://flipboxfactory.com/software/force/license
6
 * @link       https://www.flipboxfactory.com/software/force/
7
 */
8
9
namespace flipbox\craft\salesforce\services;
10
11
use flipbox\craft\integration\services\IntegrationConnections;
12
use flipbox\craft\salesforce\Force;
13
use flipbox\craft\salesforce\records\Connection;
14
use Flipbox\Salesforce\Connections\ConnectionInterface;
15
16
/**
17
 * @author Flipbox Factory <[email protected]>
18
 * @since 1.0.0
19
 */
20
class Connections extends IntegrationConnections
21
{
22
    /**
23
     * The override file
24
     */
25
    public $overrideFile = 'salesforce-connections';
26
27
    /**
28
     * @inheritdoc
29
     */
30
    protected static function tableName(): string
31
    {
32
        return Connection::tableName();
33
    }
34
35
    /**
36
     * @inheritdoc
37
     */
38
    protected static function connectionInstance(): string
39
    {
40
        return ConnectionInterface::class;
41
    }
42
43
    /**
44
     * @inheritdoc
45
     */
46
    protected function getDefaultConnection(): string
47
    {
48
        return Force::getInstance()->getSettings()->getDefaultConnection();
49
    }
50
}
51