SofortStartParameters::get_array()   A
last analyzed

Complexity

Conditions 1
Paths 1

Size

Total Lines 7
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
cc 1
eloc 4
nc 1
nop 0
dl 0
loc 7
ccs 0
cts 5
cp 0
crap 2
rs 10
c 0
b 0
f 0
1
<?php
2
3
namespace Pronamic\WordPress\Pay\Gateways\TargetPay;
4
5
/**
6
 * Title: TargetPay SOFORT Banking start parameters
7
 * Description:
8
 * Copyright: 2005-2021 Pronamic
9
 * Company: Pronamic
10
 *
11
 * @author  Remco Tolsma
12
 * @version 2.0.0
13
 * @since   1.0.0
14
 */
15
class SofortStartParameters extends StartParameters {
16
	/**
17
	 * Type
18
	 *
19
	 * @var string
20
	 */
21
	public $type;
22
23
	/**
24
	 * User IP
25
	 *
26
	 * @var string
27
	 */
28
	public $user_ip;
29
30
	/**
31
	 * Get array
32
	 *
33
	 * @rerturn array
34
	 */
35
	public function get_array() {
36
		$array = parent::get_array();
37
38
		$array['userip'] = $this->user_ip;
39
		$array['type']   = $this->type;
40
41
		return $array;
42
	}
43
}
44