Issues (4)

src/variables/RomanVariable.php (2 issues)

1
<?php
2
/**
3
 * Roman plugin for Craft CMS 3.x
4
 *
5
 * Convert an integer into roman numerals and vice versa.
6
 *
7
 * @link      dominion-designs.com
8
 * @copyright Copyright (c) 2019 Jalen Davenport
9
 */
10
11
namespace jalendport\roman\variables;
12
13
use jalendport\roman\Roman;
14
15
/**
16
 * Roman Variable
17
 *
18
 * @author    Jalen Davenport
19
 * @package   Roman
20
 * @since     1.0.0
21
 */
22
class RomanVariable
23
{
24
	
25
	/**
26
	 * @param null $number
0 ignored issues
show
Documentation Bug introduced by
Are you sure the doc-type for parameter $number is correct as it would always require null to be passed?
Loading history...
27
	 * @return string|null
28
	 */
29
	public function getRoman($number = null)
30
	{
31
    	return Roman::$plugin->romanService->getRoman($number);
32
    }
33
	
34
	/**
35
	 * @param null $romanNumerals
0 ignored issues
show
Documentation Bug introduced by
Are you sure the doc-type for parameter $romanNumerals is correct as it would always require null to be passed?
Loading history...
36
	 * @return string|null
37
	 */
38
	public function getNumber($romanNumerals = null)
39
	{
40
		return Roman::$plugin->romanService->getNumber($romanNumerals);
41
	}
42
	
43
	/**
44
	 * @return string|null
45
	 */
46
	public function currentYear()
47
	{
48
		return Roman::$plugin->romanService->getRoman(date('Y'));
49
	}
50
}
51