Passed
Push — nullBounds ( b3e7e4...f3529c )
by no
03:35
created

BasicNumberLocalizer   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 16
Duplicated Lines 0 %

Coupling/Cohesion

Components 0
Dependencies 0

Importance

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

1 Method

Rating   Name   Duplication   Size   Complexity  
A localizeNumber() 0 3 1
1
<?php
2
3
namespace ValueFormatters;
4
5
/**
6
 * Basic (dummy) localizer.
7
 *
8
 * @see \ValueParsers\NumberUnlocalizer
9
 *
10
 * @since 0.3
11
 *
12
 * @license GPL-2.0+
13
 * @author Daniel Kinzler
14
 */
15
class BasicNumberLocalizer implements NumberLocalizer {
16
17
	/**
18
	 * @see NumberLocalizer::localizeNumber
19
	 *
20
	 * Returns PHP's default representation of the given number.
21
	 *
22
	 * @param string|int|float $number
23
	 *
24
	 * @return string
25
	 */
26
	public function localizeNumber( $number ) {
27
		return "$number";
28
	}
29
30
}
31